Alexandre Julliard : winex11: Release the keyboard lock before sending input to the server.
Alexandre Julliard
julliard at winehq.org
Fri Aug 17 10:37:46 CDT 2012
Module: wine
Branch: master
Commit: 03d377eae78243b26df2dbfb32faf8324335a513
URL: http://source.winehq.org/git/wine.git/?a=commit;h=03d377eae78243b26df2dbfb32faf8324335a513
Author: Alexandre Julliard <julliard at winehq.org>
Date: Fri Aug 17 10:06:41 2012 +0200
winex11: Release the keyboard lock before sending input to the server.
---
dlls/winex11.drv/keyboard.c | 17 ++++++++---------
1 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/dlls/winex11.drv/keyboard.c b/dlls/winex11.drv/keyboard.c
index 2ccacb7..ae7e72b 100644
--- a/dlls/winex11.drv/keyboard.c
+++ b/dlls/winex11.drv/keyboard.c
@@ -1417,18 +1417,17 @@ void X11DRV_KeyEvent( HWND hwnd, XEvent *xev )
TRACE_(key)("keycode %u converted to vkey 0x%X scan %02x\n",
event->keycode, vkey, bScan);
- if (vkey)
- {
- dwFlags = 0;
- if ( event->type == KeyRelease ) dwFlags |= KEYEVENTF_KEYUP;
- if ( vkey & 0x100 ) dwFlags |= KEYEVENTF_EXTENDEDKEY;
+ LeaveCriticalSection( &kbd_section );
- update_lock_state( hwnd, vkey, event->state, event_time );
+ if (!vkey) return;
- X11DRV_send_keyboard_input( hwnd, vkey & 0xff, bScan, dwFlags, event_time );
- }
- LeaveCriticalSection( &kbd_section );
+ dwFlags = 0;
+ if ( event->type == KeyRelease ) dwFlags |= KEYEVENTF_KEYUP;
+ if ( vkey & 0x100 ) dwFlags |= KEYEVENTF_EXTENDEDKEY;
+
+ update_lock_state( hwnd, vkey, event->state, event_time );
+ X11DRV_send_keyboard_input( hwnd, vkey & 0xff, bScan, dwFlags, event_time );
}
/**********************************************************************
More information about the wine-cvs
mailing list