[Win32k]
[reactos.git] / reactos / dll / win32 / user32 / windows / window.c
index d2a7bb9..4cc757f 100644 (file)
@@ -65,17 +65,7 @@ AllowSetForegroundWindow(DWORD dwProcessId)
 HDWP WINAPI
 BeginDeferWindowPos(int nNumWindows)
 {
-    if (nNumWindows < 0)
-    {
-        SetLastError(ERROR_INVALID_PARAMETER);
-        return 0;
-    }
-#if 0
-    UNIMPLEMENTED;
-    return (HDWP)0;
-#else
-    return (HDWP)1;
-#endif
+    return (HDWP)NtUserCallOneParam((DWORD_PTR)nNumWindows, ONEPARAM_ROUTINE_BEGINDEFERWNDPOS);
 }
 
 
@@ -567,12 +557,7 @@ DeferWindowPos(HDWP hWinPosInfo,
                int cy,
                UINT uFlags)
 {
-#if 0
     return NtUserDeferWindowPos(hWinPosInfo, hWnd, hWndInsertAfter, x, y, cx, cy, uFlags);
-#else
-    SetWindowPos(hWnd, hWndInsertAfter, x, y, cx, cy, uFlags);
-    return hWinPosInfo;
-#endif
 }
 
 
@@ -582,12 +567,7 @@ DeferWindowPos(HDWP hWinPosInfo,
 BOOL WINAPI
 EndDeferWindowPos(HDWP hWinPosInfo)
 {
-#if 0
-    UNIMPLEMENTED;
-    return FALSE;
-#else
-    return TRUE;
-#endif
+    return NtUserEndDeferWindowPosEx(hWinPosInfo, 0);
 }
 
 
@@ -1727,7 +1707,7 @@ SetWindowTextA(HWND hWnd,
 
         if ((GetWindowLongPtrW(hWnd, GWL_STYLE) & WS_CAPTION) == WS_CAPTION)
         {
-            DefWndNCPaint(hWnd, (HRGN)1, -1);
+            DefWndNCPaint(hWnd, HRGN_WINDOW, -1);
         }
         return TRUE;
     }
@@ -1757,7 +1737,7 @@ SetWindowTextW(HWND hWnd,
 
         if ((GetWindowLongPtrW(hWnd, GWL_STYLE) & WS_CAPTION) == WS_CAPTION)
         {
-            DefWndNCPaint(hWnd, (HRGN)1, -1);
+            DefWndNCPaint(hWnd, HRGN_WINDOW, -1);
         }
         return TRUE;
     }