winex11: Release the keyboard lock before sending input to the server.

This commit is contained in:
Alexandre Julliard 2012-08-17 10:06:41 +02:00
parent dc9f5becd1
commit 03d377eae7
1 changed files with 9 additions and 10 deletions

View File

@ -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;
update_lock_state( hwnd, vkey, event->state, event_time );
X11DRV_send_keyboard_input( hwnd, vkey & 0xff, bScan, dwFlags, event_time );
}
LeaveCriticalSection( &kbd_section );
if (!vkey) return;
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 );
}
/**********************************************************************