Details
-
Bug
-
Resolution: Cannot Reproduce
-
P1: Critical
-
5.1.1
-
None
-
OSX
Description
If you derive from QWidget and re-implement wheelEvent to test for a keyboard modifier, it doesn't work.
class Wid : public QWidget { Q_OBJECT public: Wid() {} protected: void wheelEvent(QWheelEvent *ev) { qDebug() << QApplication::keyboardModifiers().testFlag(Qt::ControlModifier); QWidget::wheelEvent(ev); } }; int main(int argc, char *argv[]) { QApplication a(argc, argv); qDebug() << qVersion(); Wid w; w.show(); return a.exec(); }
It does work in mousePress and mouseMove however.
This is a regression since Qt 4.