[WIN32K]
[reactos.git] / reactos / subsystems / win32 / win32k / ntuser / timer.c
index b65a2eb..1c34ab7 100644 (file)
@@ -11,7 +11,7 @@
 
 /* INCLUDES ******************************************************************/
 
-#include <w32k.h>
+#include <win32k.h>
 
 #define NDEBUG
 #include <debug.h>
@@ -253,7 +253,7 @@ StartTheTimers(VOID)
 
 UINT_PTR
 FASTCALL
-SetSystemTimer( PWINDOW_OBJECT Window,
+SystemTimerSet( PWINDOW_OBJECT Window,
                 UINT_PTR nIDEvent,
                 UINT uElapse,
                 TIMERPROC lpTimerFunc) 
@@ -279,7 +279,9 @@ PostTimerMessages(PWINDOW_OBJECT Window)
 
   if (!pTmr) return FALSE;
 
-  if (Window && (int)Window != 1)
+  ASSERT(Window);
+
+  if (Window && ((ULONG_PTR)Window != 1))
   {
      if (!Window->Wnd) return FALSE;
   }
@@ -294,6 +296,7 @@ PostTimerMessages(PWINDOW_OBJECT Window)
           (pTmr->pti == pti) &&
           (pTmr->pWnd == Window))
         {
+           ASSERT((ULONG_PTR)Window != 1);
            Msg.hwnd    = Window->hSelf;
            Msg.message = (pTmr->flags & TMRF_SYSTEM) ? WM_SYSTIMER : WM_TIMER;
            Msg.wParam  = (WPARAM) pTmr->nID;
@@ -526,6 +529,8 @@ IntKillTimer(HWND Wnd, UINT_PTR IDEvent, BOOL SystemTimer)
       ASSERT(RtlAreBitsSet(&WindowLessTimersBitMap, IDEvent - 1, 1));
       RtlClearBits(&WindowLessTimersBitMap, IDEvent - 1, 1);
 
+      HintIndex = IDEvent - 1;
+
       IntUnlockWindowlessTimerBitmap();
    }