summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Huddleston <jeremyhu@freedesktop.org>2008-12-31 19:57:49 (GMT)
committerJeremy Huddleston <jeremyhu@freedesktop.org>2008-12-31 20:45:08 (GMT)
commit0d2621b6d4684ec62e67156a5a9dbdd3297f9cb0 (patch)
tree8655057446e3cd047c138a0b6aca6e6b734ef61c
parent9faf3de7e5610af340b92acb1b86bf03b6f2241a (diff)
XQuartz: Make sure to reset the saved key state when deactivating X11.app
(cherry picked from commit 3eef78eb321f4f7dbca5a10c80666c621e28a1e0)
-rw-r--r--hw/xquartz/X11Application.m4
1 files changed, 3 insertions, 1 deletions
diff --git a/hw/xquartz/X11Application.m b/hw/xquartz/X11Application.m
index cbf5cba..cd5ab5c 100644
--- a/hw/xquartz/X11Application.m
+++ b/hw/xquartz/X11Application.m
@@ -202,8 +202,10 @@ static void message_kit_thread (SEL selector, NSObject *arg) {
DarwinUpdateModKeys(0);
for(i=0; i < NUM_KEYCODES; i++) {
- if(keyState[i] == NSKeyDown)
+ if(keyState[i] == NSKeyDown) {
DarwinSendKeyboardEvents(KeyRelease, i);
+ keyState[i] = NSKeyUp;
+ }
}
DarwinSendDDXEvent(kXquartzDeactivate, 0);