fixed a bug in qt