PDA

View Full Version : Events



A9am
10th November 2011, 11:31
Hai all,


If I reimplement any event in my application , will the default event get executed?

For Example, I reimplemented wheelEvent in my program and I am doing nothing in that event handler.While executing program, if I use mouse wheel will it go to default or to my handler?



Thanks

Wolf900
10th November 2011, 14:08
If it's reimplemented, it should go to the reimplemented function in your class.

When in trouble, you could test things like that with qDebug. Just pass a message to display on the Application Output panel to be sure it's working.


#include <QDebug>
...
void MyClass::wheelEvent (QWheelEvent * event){
qDebug() << "Wheel scrolled!";
}