Hi Everybody,

I am working with qt3.3.8b.

I add a QKeyEvent as describe below:

Qt Code:
  1. ....
  2. QWidget* targetWidget = QApplication::focusWidget();
  3. QKeyEvent kev(QEvent::KeyPress, Qt::Key_F1, 0, Qt::NoButton, NULL, false, 1);
  4. QApplication::sendEvent(targetWidget, &kev);
  5. .....
To copy to clipboard, switch view to plain text mode 

It works fine on the main widget::keyPressEvent(QKeyEvent *k), i can receive
the key, also the QLineEdit are working fine.

With the QBushButton even if i define setAccel(Qt::Key_F1), there is no way to works out.
If i press F1 on the keybord the button works but it does not calling the sendEvent.

Is there anybody can give me a typ about that?

Thanks in advance
Ezio