Author: jimtabor
Date: Sun Oct 3 19:18:19 2010
New Revision: 48970
URL:
http://svn.reactos.org/svn/reactos?rev=48970&view=rev
Log:
[Win32k]
- Fixed ValidateTimerCallback, always returning true and just spinning in the loop.
- Add one more process information flag with a point type and capturing the hit test in
desktop structure.
Modified:
trunk/reactos/subsystems/win32/win32k/include/timer.h
trunk/reactos/subsystems/win32/win32k/include/win32.h
trunk/reactos/subsystems/win32/win32k/ntuser/message.c
trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c
trunk/reactos/subsystems/win32/win32k/ntuser/timer.c
Modified: trunk/reactos/subsystems/win32/win32k/include/timer.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/include/timer.h [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/include/timer.h [iso-8859-1] Sun Oct 3 19:18:19
2010
@@ -32,7 +32,7 @@
BOOL FASTCALL IntKillTimer(PWINDOW_OBJECT Window, UINT_PTR IDEvent, BOOL SystemTimer);
UINT_PTR FASTCALL IntSetTimer(PWINDOW_OBJECT Window, UINT_PTR IDEvent, UINT Elapse,
TIMERPROC TimerFunc, INT Type);
PTIMER FASTCALL FindSystemTimer(PMSG);
-BOOL FASTCALL ValidateTimerCallback(PTHREADINFO,PWINDOW_OBJECT,WPARAM,LPARAM);
+BOOL FASTCALL ValidateTimerCallback(PTHREADINFO,LPARAM);
VOID CALLBACK SystemTimerProc(HWND,UINT,UINT_PTR,DWORD);
UINT_PTR FASTCALL SystemTimerSet(PWINDOW_OBJECT,UINT_PTR,UINT,TIMERPROC);
BOOL FASTCALL PostTimerMessages(PWINDOW_OBJECT);
Modified: trunk/reactos/subsystems/win32/win32k/include/win32.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/include/win32.h [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/include/win32.h [iso-8859-1] Sun Oct 3 19:18:19
2010
@@ -25,6 +25,7 @@
#define W32PF_SCREENSAVER 0x00200000
#define W32PF_IDLESCREENSAVER 0x00400000
#define W32PF_ICONTITLEREGISTERED 0x10000000
+#define W32PF_DPIAWARE 0x20000000
// ReactOS
#define W32PF_NOWINDOWGHOSTING (0x01000000)
#define W32PF_MANUALGUICHECK (0x02000000)
@@ -93,6 +94,7 @@
HANDLE hEventQueueClient;
PKEVENT pEventQueueServer;
LIST_ENTRY PtiLink;
+ POINT ptLast;
CLIENTTHREADINFO cti; // Used only when no Desktop or pcti NULL.
/* ReactOS */
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/message.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/message.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/message.c [iso-8859-1] Sun Oct 3
19:18:19 2010
@@ -394,7 +394,7 @@
{
if (pMsg->message == WM_TIMER)
{
- if
(ValidateTimerCallback(PsGetCurrentThreadWin32Thread(),Window,pMsg->wParam,pMsg->lParam))
+ if (ValidateTimerCallback(PsGetCurrentThreadWin32Thread(),pMsg->lParam))
{
KeQueryTickCount(&TickCount);
Time = MsqCalculateMessageTime(&TickCount);
@@ -963,13 +963,15 @@
}
MsgExit:
+ pti->rpdesk->htEx = HitTest; /* Now set the capture hit. */
+
if ( ISITHOOKED(WH_MOUSE) && IS_MOUSE_MESSAGE(Msg->Msg.message))
{
- if(!ProcessMouseMessage(&Msg->Msg, HitTest, RemoveMsg))
- {
- return FALSE;
- }
- }
+ if (!ProcessMouseMessage(&Msg->Msg, HitTest, RemoveMsg))
+ {
+ return FALSE;
+ }
+ }
if ( ISITHOOKED(WH_KEYBOARD) && IS_KBD_MESSAGE(Msg->Msg.message))
{
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c [iso-8859-1] Sun Oct 3
19:18:19 2010
@@ -1125,20 +1125,11 @@
LPARAM lParam)
{
BOOL Ret = FALSE;
- PWINDOW_OBJECT Window = NULL;
UserEnterShared();
- if (hWnd)
- {
- Window = UserGetWindowObject(hWnd);
- if (!Window || !Window->Wnd)
- goto Exit;
- }
-
- Ret = ValidateTimerCallback(PsGetCurrentThreadWin32Thread(), Window, wParam, lParam);
-
-Exit:
+ Ret = ValidateTimerCallback(PsGetCurrentThreadWin32Thread(), lParam);
+
UserLeave();
return Ret;
}
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/timer.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/timer.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/timer.c [iso-8859-1] Sun Oct 3 19:18:19
2010
@@ -167,11 +167,10 @@
BOOL
FASTCALL
ValidateTimerCallback(PTHREADINFO pti,
- PWINDOW_OBJECT Window,
- WPARAM wParam,
LPARAM lParam)
{
PLIST_ENTRY pLE;
+ BOOL Ret = FALSE;
PTIMER pTmr = FirstpTmr;
if (!pTmr) return FALSE;
@@ -180,18 +179,18 @@
do
{
if ( (lParam == (LPARAM)pTmr->pfn) &&
- (pTmr->flags & (TMRF_SYSTEM|TMRF_RIT)) &&
+ !(pTmr->flags & (TMRF_SYSTEM|TMRF_RIT)) &&
(pTmr->pti->ppi == pti->ppi) )
+ {
+ Ret = TRUE;
break;
-
+ }
pLE = pTmr->ptmrList.Flink;
pTmr = CONTAINING_RECORD(pLE, TIMER, ptmrList);
} while (pTmr != FirstpTmr);
TimerLeave();
- if (!pTmr) return FALSE;
-
- return TRUE;
+ return Ret;
}
UINT_PTR FASTCALL
@@ -616,8 +615,7 @@
DPRINT("Enter NtUserSetSystemTimer\n");
- // This is wrong, lpTimerFunc is NULL!
- RETURN(IntSetTimer(UserGetWindowObject(hWnd), nIDEvent, uElapse, lpTimerFunc,
TMRF_SYSTEM));
+ RETURN(IntSetTimer(UserGetWindowObject(hWnd), nIDEvent, uElapse, NULL, TMRF_SYSTEM));
CLEANUP:
DPRINT("Leave NtUserSetSystemTimer, ret=%i\n", _ret_);