diff options
author | Paul Olav Tvete <paul.tvete@nokia.com> | 2010-03-03 14:41:38 (GMT) |
---|---|---|
committer | Paul Olav Tvete <paul.tvete@nokia.com> | 2010-03-03 14:47:57 (GMT) |
commit | 57b6629507e97c63cf2445eef12443dcb2639887 (patch) | |
tree | 75e49b782a57b581c8c6112edb4ee15b98b0a929 /src | |
parent | 7dacb5be7a97657754c844882f9e68365fd474d4 (diff) | |
download | Qt-57b6629507e97c63cf2445eef12443dcb2639887.zip Qt-57b6629507e97c63cf2445eef12443dcb2639887.tar.gz Qt-57b6629507e97c63cf2445eef12443dcb2639887.tar.bz2 |
Support keypad input with vnc driver
Task-number: QT-1849
Reviewed-by: Jeremy
Diffstat (limited to 'src')
-rw-r--r-- | src/plugins/gfxdrivers/vnc/qscreenvnc_qws.cpp | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/src/plugins/gfxdrivers/vnc/qscreenvnc_qws.cpp b/src/plugins/gfxdrivers/vnc/qscreenvnc_qws.cpp index 7bcb74d..e78fec1 100644 --- a/src/plugins/gfxdrivers/vnc/qscreenvnc_qws.cpp +++ b/src/plugins/gfxdrivers/vnc/qscreenvnc_qws.cpp @@ -325,6 +325,36 @@ static const struct { { 0xffe8, Qt::Key_Meta }, { 0xffe9, Qt::Key_Alt }, { 0xffea, Qt::Key_Alt }, + + { 0xffb0, Qt::Key_0 }, + { 0xffb1, Qt::Key_1 }, + { 0xffb2, Qt::Key_2 }, + { 0xffb3, Qt::Key_3 }, + { 0xffb4, Qt::Key_4 }, + { 0xffb5, Qt::Key_5 }, + { 0xffb6, Qt::Key_6 }, + { 0xffb7, Qt::Key_7 }, + { 0xffb8, Qt::Key_8 }, + { 0xffb9, Qt::Key_9 }, + + { 0xff8d, Qt::Key_Return }, + { 0xffaa, Qt::Key_Asterisk }, + { 0xffab, Qt::Key_Plus }, + { 0xffad, Qt::Key_Minus }, + { 0xffae, Qt::Key_Period }, + { 0xffaf, Qt::Key_Slash }, + + { 0xff95, Qt::Key_Home }, + { 0xff96, Qt::Key_Left }, + { 0xff97, Qt::Key_Up }, + { 0xff98, Qt::Key_Right }, + { 0xff99, Qt::Key_Down }, + { 0xff9a, Qt::Key_PageUp }, + { 0xff9b, Qt::Key_PageDown }, + { 0xff9c, Qt::Key_End }, + { 0xff9e, Qt::Key_Insert }, + { 0xff9f, Qt::Key_Delete }, + { 0, 0 } }; @@ -483,6 +513,10 @@ bool QRfbKeyEvent::read(QTcpSocket *s) keycode = keyMap[i].keycode; i++; } + + if (keycode >= ' ' && keycode <= '~') + unicode = keycode; + if (!keycode) { if (key <= 0xff) { unicode = key; |