Alexandre Julliard : user32: Move thread info setting and WH_GETMESSAGE call into peek_message.
Alexandre Julliard
julliard at winehq.org
Wed Oct 29 09:39:21 CDT 2008
Module: wine
Branch: master
Commit: 641cc6402f35396c560458427527f0df09b7b6f1
URL: http://source.winehq.org/git/wine.git/?a=commit;h=641cc6402f35396c560458427527f0df09b7b6f1
Author: Alexandre Julliard <julliard at winehq.org>
Date: Wed Oct 29 12:12:21 2008 +0100
user32: Move thread info setting and WH_GETMESSAGE call into peek_message.
---
dlls/user32/message.c | 13 +++++--------
1 files changed, 5 insertions(+), 8 deletions(-)
diff --git a/dlls/user32/message.c b/dlls/user32/message.c
index 597ad71..82350a3 100644
--- a/dlls/user32/message.c
+++ b/dlls/user32/message.c
@@ -2174,7 +2174,6 @@ static BOOL peek_message( MSG *msg, HWND hwnd, UINT first, UINT last, UINT flags
info.msg.message, flags | PM_REMOVE );
goto next;
}
- thread_info->GetMessageExtraInfoVal = extra_info;
if (info.msg.message >= WM_DDE_FIRST && info.msg.message <= WM_DDE_LAST)
{
if (!unpack_dde_message( info.msg.hwnd, info.msg.message, &info.msg.wParam,
@@ -2182,7 +2181,12 @@ static BOOL peek_message( MSG *msg, HWND hwnd, UINT first, UINT last, UINT flags
goto next; /* ignore it */
}
*msg = info.msg;
+ msg->pt.x = (short)LOWORD( thread_info->GetMessagePosVal );
+ msg->pt.y = (short)HIWORD( thread_info->GetMessagePosVal );
+ thread_info->GetMessageTimeVal = info.msg.time;
+ thread_info->GetMessageExtraInfoVal = extra_info;
HeapFree( GetProcessHeap(), 0, buffer );
+ HOOK_CallHooks( WH_GETMESSAGE, HC_ACTION, flags & PM_REMOVE, (LPARAM)msg, TRUE );
return TRUE;
}
@@ -2870,7 +2874,6 @@ void WINAPI PostQuitMessage( INT exit_code )
*/
BOOL WINAPI PeekMessageW( MSG *msg_out, HWND hwnd, UINT first, UINT last, UINT flags )
{
- struct user_thread_info *thread_info = get_user_thread_info();
MSG msg;
USER_CheckNotLock();
@@ -2890,12 +2893,6 @@ BOOL WINAPI PeekMessageW( MSG *msg_out, HWND hwnd, UINT first, UINT last, UINT f
return FALSE;
}
- thread_info->GetMessageTimeVal = msg.time;
- msg.pt.x = (short)LOWORD( thread_info->GetMessagePosVal );
- msg.pt.y = (short)HIWORD( thread_info->GetMessagePosVal );
-
- HOOK_CallHooks( WH_GETMESSAGE, HC_ACTION, flags & PM_REMOVE, (LPARAM)&msg, TRUE );
-
/* copy back our internal safe copy of message data to msg_out.
* msg_out is a variable from the *program*, so it can't be used
* internally as it can get "corrupted" by our use of SendMessage()
More information about the wine-cvs
mailing list