This is a regression relative to 4.4.3. Test under Windows. The problem is
that QApplication::keyboardModifiers() returns inverted results once a
  modifier key has been pressed or released. The following example
  illustrates this. Run the program and move the mouse over the window
  and look at the debugger console. As you can see, results are wrong.
  The same program works fine with 4.4.3.

I think this bug is likely to harm many existing applications, I would
tag it as "show stopper".

////////////

#include <QtGui>

class TMainWindow : public QMainWindow
{
public:
     TMainWindow(QWidget* parent = 0)
         :
         QMainWindow(parent)
         {
                        setMouseTracking(true);
                        resize(800,400);
         }

        void mouseMoveEvent(QMouseEvent *)
        {
                qWarning("Mod %d", QApplication::keyboardModifiers());
        }
};

int main (int argc, char** argv)
{
     QApplication app(argc, argv);
     TMainWindow w ;
     w.show();
     return app.exec();
}

//////////////
_______________________________________________
Qt4-preview-feedback mailing list
[email protected]
http://lists.trolltech.com/mailman/listinfo/qt4-preview-feedback

Reply via email to