From c8fff05661a6f52ef8728c136836b8246a56b017 Mon Sep 17 00:00:00 2001 From: James Tabor Date: Wed, 24 Feb 2016 08:41:26 +0000 Subject: [PATCH] [Win32SS] - Fix all wine win:test_GetMessagePos tests. - See CORE-10867, please verify this is a fix. svn path=/trunk/; revision=70782 --- reactos/win32ss/user/ntuser/msgqueue.c | 8 ++++++++ reactos/win32ss/user/ntuser/timer.c | 2 ++ 2 files changed, 10 insertions(+) diff --git a/reactos/win32ss/user/ntuser/msgqueue.c b/reactos/win32ss/user/ntuser/msgqueue.c index 7187909c731..eb48f943c50 100644 --- a/reactos/win32ss/user/ntuser/msgqueue.c +++ b/reactos/win32ss/user/ntuser/msgqueue.c @@ -1982,6 +1982,14 @@ co_MsqPeekHardwareMessage(IN PTHREADINFO pti, if (AcceptMessage) { *pMsg = msg; + // Fix all but one wine win:test_GetMessagePos WM_TIMER tests. See PostTimerMessages. + if (!RtlEqualMemory(&pti->ptLast, &msg.pt, sizeof(POINT))) + { + pti->TIF_flags |= TIF_MSGPOSCHANGED; + } + pti->ptLast = msg.pt; + pti->timeLast = msg.time; + MessageQueue->ExtraInfo = ExtraInfo; Ret = TRUE; break; } diff --git a/reactos/win32ss/user/ntuser/timer.c b/reactos/win32ss/user/ntuser/timer.c index d2789bb1024..49ee063fe1a 100644 --- a/reactos/win32ss/user/ntuser/timer.c +++ b/reactos/win32ss/user/ntuser/timer.c @@ -415,6 +415,8 @@ PostTimerMessages(PWND Window) Msg.message = (pTmr->flags & TMRF_SYSTEM) ? WM_SYSTIMER : WM_TIMER; Msg.wParam = (WPARAM) pTmr->nID; Msg.lParam = (LPARAM) pTmr->pfn; + // Fix all wine win:test_GetMessagePos WM_TIMER tests. See CORE-10867. + Msg.pt = gpsi->ptCursor; MsqPostMessage(pti, &Msg, FALSE, (QS_POSTMESSAGE|QS_ALLPOSTMESSAGE), 0, 0); pTmr->flags &= ~TMRF_READY;