From: Giannis Adamopoulos Date: Thu, 28 Apr 2011 19:26:09 +0000 (+0000) Subject: [win32k] X-Git-Tag: backups/ros-amd64-bringup@60669^2~860 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=654d08212ed723dd6d955de1c5bd05592f36cef1;hp=f685f1aeb0c7032d881d2c8ab26308b5e5341f47 [win32k] - Call update_input_key_state correctly svn path=/trunk/; revision=51479 --- diff --git a/reactos/subsystems/win32/win32k/ntuser/msgqueue.c b/reactos/subsystems/win32/win32k/ntuser/msgqueue.c index cd57a5082a5..e0210dafdc1 100644 --- a/reactos/subsystems/win32/win32k/ntuser/msgqueue.c +++ b/reactos/subsystems/win32/win32k/ntuser/msgqueue.c @@ -52,8 +52,7 @@ DWORD FASTCALL UserGetKeyState(DWORD key) if( key < 0x100 ) { - ret = ((DWORD)(MessageQueue->KeyState[key] & KS_DOWN_BIT) << 8 ) | - (MessageQueue->KeyState[key] & KS_LOCK_BIT); + ret = (DWORD)MessageQueue->KeyState[key]; } return ret; @@ -62,6 +61,8 @@ DWORD FASTCALL UserGetKeyState(DWORD key) /* change the input key state for a given key */ static void set_input_key_state( PUSER_MESSAGE_QUEUE MessageQueue, UCHAR key, BOOL down ) { + DPRINT("set_input_key_state key:%d, down:%d\n", key, down); + if (down) { if (!(MessageQueue->KeyState[key] & KS_DOWN_BIT)) @@ -82,6 +83,8 @@ static void update_input_key_state( PUSER_MESSAGE_QUEUE MessageQueue, MSG* msg ) UCHAR key; BOOL down = 0; + DPRINT("update_input_key_state message:%d\n", msg->message); + switch (msg->message) { case WM_LBUTTONDOWN: @@ -1465,7 +1468,7 @@ co_MsqPeekHardwareMessage(IN PUSER_MESSAGE_QUEUE MessageQueue, if (Remove) { - update_input_key_state(MessageQueue, pMsg); + update_input_key_state(MessageQueue, &msg); RemoveEntryList(&CurrentMessage->ListEntry); ClearMsgBitsMask(MessageQueue, CurrentMessage->QS_Flags); MsqDestroyMessage(CurrentMessage);