[webkit-qt] Custom keycodes not accepted
massimocallegari at yahoo.it
Fri Sep 5 04:01:34 PDT 2014
I am developing my own IR remote control driver inside the eglfs plugin. I submit the keycodes to the upper layers like this:
QWindowSystemInterface::handleKeyEvent(0, QEvent::KeyPress, keyCode, Qt::NoModifier);
QWindowSystemInterface::handleKeyEvent(0, QEvent::KeyRelease, keyCode, Qt::NoModifier);
In my previous system I was using QtWebKit 2.3.3 + Qt 4.8.6 + DirectFB and it was working fine with the same keycodes.
In my simple browser application I redefined the keyPressEvent method like this:
void MainWindow::keyPressEvent(QKeyEvent *ev)
qDebug() << "key pressed:" << ev->key() << "accepted:" << ev->isAccepted();
qDebug() << "Event accepted";
qDebug() << "Event NOT accepted";
m_view is a pointer to QWebView.
I receive all the keycodes and at the beginning of the function the events are still marked as accepted.
Is there a particular reason for this or is there a way to workaround it ?
Thanks in advance,
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the webkit-qt