Details
-
Bug
-
Resolution: Done
-
P2: Important
-
4.6.0
-
None
-
Leopard Only
-
several, starting with 0cb155516992d3bb917f72bdab9f28b9e65ff40d
Description
Only on Leopard, Snow Leopard seems to work OK.
When a QFontDialog (cocoa based) is opened from a modal QDialog to a QMainWindow is open and the user mouses over the QMainWindow focus shifts to the QDialog from the QFontDialog, and it is not possible to set focus back to the QFontDialog.
Here is a sample that reproduces the issue :
#include <QtGui> class Dialog : public QDialog { Q_OBJECT public: Dialog(QWidget *parent) : QDialog(parent) { // setWindowModality(Qt::WindowModal); QTimer::singleShot(1000,this,SLOT(col())); } public slots: void col() { bool bOk; QFontDialog::getFont(&bOk, QFont("Helvetica", 12), this); } }; class Widget : public QMainWindow { public: Widget() { }; void dia() { Dialog dialog(this); dialog.move(200,200); dialog.exec(); } }; #include "main.moc" int main(int argc, char *argv[]) { QApplication a(argc, argv); Widget w; w.show(); w.move(50,50); w.dia(); return a.exec(); }