summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/vnc/qvnc.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@theqtcompany.com>2015-12-16 22:41:04 +0100
committerAndy Nichols <andy.nichols@qt.io>2016-06-28 10:18:15 +0000
commit53f7e565db860a9993c79139b941999d206f0b1d (patch)
tree19d4e409a357837fa808334308dcef1d92bebf83 /src/plugins/platforms/vnc/qvnc.cpp
parent1955da90a0503b8419e5cab87c915f7fd29af0cf (diff)
Implement support for key events in the VNC plugin
Make sure we receive key events from the VNC client and forward them to the app through the QPA interface. Change-Id: I8d44d614670ec753e35ff36fa3ef2d74b07f4bbc Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Diffstat (limited to 'src/plugins/platforms/vnc/qvnc.cpp')
-rw-r--r--src/plugins/platforms/vnc/qvnc.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/plugins/platforms/vnc/qvnc.cpp b/src/plugins/platforms/vnc/qvnc.cpp
index 25e1be5d24..6948344701 100644
--- a/src/plugins/platforms/vnc/qvnc.cpp
+++ b/src/plugins/platforms/vnc/qvnc.cpp
@@ -1088,9 +1088,8 @@ void QVncServer::keyEvent()
else if (ev.keycode == Qt::Key_Alt)
keymod = ev.down ? keymod | Qt::AltModifier :
keymod & ~Qt::AltModifier;
- // #####
-// if (ev.unicode || ev.keycode)
-// QWSServer::sendKeyEvent(ev.unicode, ev.keycode, keymod, ev.down, false);
+ if (ev.unicode || ev.keycode)
+ QWindowSystemInterface::handleKeyEvent(0, ev.down ? QEvent::KeyPress : QEvent::KeyRelease, ev.keycode, keymod, QString(ev.unicode));
handleMsg = false;
}
}