diff options
author | Kaleb Keithley <kaleb@freedesktop.org> | 2003-11-25 19:29:01 +0000 |
---|---|---|
committer | Kaleb Keithley <kaleb@freedesktop.org> | 2003-11-25 19:29:01 +0000 |
commit | adc7f9a4ebdfe11d4cd6de9388b63dfe36450b39 (patch) | |
tree | 23eb7becc5360b2cbe16aa8d45529880067f3989 /hw/xwin/winkeybd.c | |
parent | 90f1536dd315cd265bfc7ef35058761a65a01734 (diff) |
XFree86 4.3.99.16 Bring the tree up to date for the Cygwin folks
Diffstat (limited to 'hw/xwin/winkeybd.c')
-rw-r--r-- | hw/xwin/winkeybd.c | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/hw/xwin/winkeybd.c b/hw/xwin/winkeybd.c index 20df053c2..95f245e57 100644 --- a/hw/xwin/winkeybd.c +++ b/hw/xwin/winkeybd.c @@ -30,7 +30,7 @@ * Peter Busch * Harold L Hunt II */ -/* $XFree86: xc/programs/Xserver/hw/xwin/winkeybd.c,v 1.12 2002/10/17 08:18:22 alanh Exp $ */ +/* $XFree86: xc/programs/Xserver/hw/xwin/winkeybd.c,v 1.13 2003/07/29 21:25:17 dawes Exp $ */ #include "win.h" @@ -649,31 +649,23 @@ void winKeybdReleaseKeys () { #if !WIN_NEW_KEYBOARD_SUPPORT -#if 0 /* Old function that just pops modifiers */ - /* Verify that the mi input system has been initialized */ - if (g_fdMessageQueue == WIN_FD_INVALID) - return; - - winSendKeyEvent (KEY_Alt, FALSE); - winSendKeyEvent (KEY_AltLang, FALSE); - winSendKeyEvent (KEY_LCtrl, FALSE); - winSendKeyEvent (KEY_RCtrl, FALSE); - winSendKeyEvent (KEY_ShiftL, FALSE); - winSendKeyEvent (KEY_ShiftR, FALSE); -#else /* New function that pops all keys */ int i; /* Verify that the mi input system has been initialized */ if (g_fdMessageQueue == WIN_FD_INVALID) return; - /* Pop any pressed keys */ + /* Loop through all keys */ for (i = 0; i < NUM_KEYCODES; ++i) { - if (g_winKeyState[i]) winSendKeyEvent (i, FALSE); + /* Pop key if pressed */ + if (g_winKeyState[i]) + winSendKeyEvent (i, FALSE); + + /* Reset pressed flag for keys */ + g_winKeyState[i] = FALSE; } #endif -#endif } |