Commit ae984f63 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

win32u: Move NtUserValidateRect implementation from user32.

parent 8bdfe2be
......@@ -176,7 +176,7 @@ LRESULT WINAPI IconTitleWndProc( HWND hWnd, UINT msg,
else
lParam = (owner == GetActiveWindow());
if( ICONTITLE_Paint( hWnd, owner, (HDC)wParam, (BOOL)lParam ) )
ValidateRect( hWnd, NULL );
NtUserValidateRect( hWnd, NULL );
return 1;
}
return DefWindowProcW( hWnd, msg, wParam, lParam );
......
......@@ -52,26 +52,6 @@ BOOL WINAPI ValidateRgn( HWND hwnd, HRGN hrgn )
}
/***********************************************************************
* ValidateRect (USER32.@)
*
* MSDN: if hwnd parameter is NULL, ValidateRect invalidates and redraws
* all windows and sends WM_ERASEBKGND and WM_NCPAINT.
*/
BOOL WINAPI ValidateRect( HWND hwnd, const RECT *rect )
{
UINT flags = RDW_VALIDATE;
if (!hwnd)
{
flags = RDW_ALLCHILDREN | RDW_INVALIDATE | RDW_FRAME | RDW_ERASE | RDW_ERASENOW;
rect = NULL;
}
return NtUserRedrawWindow( hwnd, rect, 0, flags );
}
/*************************************************************************
* ScrollWindow (USER32.@)
*
......
......@@ -807,7 +807,7 @@
@ stdcall UserSignalProc(long long long long)
# @ stub VRipOutput
# @ stub VTagOutput
@ stdcall ValidateRect(long ptr)
@ stdcall ValidateRect(long ptr) NtUserValidateRect
@ stdcall ValidateRgn(long long)
@ stdcall VkKeyScanA(long)
@ stdcall VkKeyScanExA(long long)
......
......@@ -1508,6 +1508,22 @@ BOOL WINAPI NtUserRedrawWindow( HWND hwnd, const RECT *rect, HRGN hrgn, UINT fla
}
/***********************************************************************
* NtUserValidateRect (win32u.@)
*/
BOOL WINAPI NtUserValidateRect( HWND hwnd, const RECT *rect )
{
UINT flags = RDW_VALIDATE;
if (!hwnd)
{
flags = RDW_ALLCHILDREN | RDW_INVALIDATE | RDW_FRAME | RDW_ERASE | RDW_ERASENOW;
rect = NULL;
}
return NtUserRedrawWindow( hwnd, rect, 0, flags );
}
/***********************************************************************
* NtUserGetUpdateRgn (win32u.@)
*/
INT WINAPI NtUserGetUpdateRgn( HWND hwnd, HRGN hrgn, BOOL erase )
......
......@@ -302,6 +302,7 @@ static void * const syscalls[] =
NtUserUnregisterClass,
NtUserUnregisterHotKey,
NtUserUpdateInputContext,
NtUserValidateRect,
NtUserVkKeyScanEx,
NtUserWaitForInputIdle,
NtUserWindowFromDC,
......
......@@ -1300,7 +1300,7 @@
@ stub NtUserUpdateWindowInputSinkHints
@ stub NtUserUpdateWindowTrackingInfo
@ stub NtUserUserHandleGrantAccess
@ stub NtUserValidateRect
@ stdcall -syscall NtUserValidateRect(long ptr)
@ stub NtUserValidateTimerCallback
@ stdcall -syscall NtUserVkKeyScanEx(long long)
@ stub NtUserWOWCleanup
......
......@@ -288,6 +288,7 @@
SYSCALL_ENTRY( NtUserUnregisterClass ) \
SYSCALL_ENTRY( NtUserUnregisterHotKey ) \
SYSCALL_ENTRY( NtUserUpdateInputContext ) \
SYSCALL_ENTRY( NtUserValidateRect ) \
SYSCALL_ENTRY( NtUserVkKeyScanEx ) \
SYSCALL_ENTRY( NtUserWaitForInputIdle ) \
SYSCALL_ENTRY( NtUserWindowFromDC ) \
......
......@@ -4102,6 +4102,14 @@ NTSTATUS WINAPI wow64_NtUserUpdateInputContext( UINT *args )
return NtUserUpdateInputContext( handle, attr, value );
}
NTSTATUS WINAPI wow64_NtUserValidateRect( UINT *args )
{
HWND hwnd = get_handle( &args );
const RECT *rect = get_ptr( &args );
return NtUserValidateRect( hwnd, rect );
}
NTSTATUS WINAPI wow64_NtUserVkKeyScanEx( UINT *args )
{
WCHAR chr = get_ulong( &args );
......
......@@ -892,6 +892,7 @@ BOOL WINAPI NtUserUpdateInputContext( HIMC handle, UINT attr, UINT_PTR value
BOOL WINAPI NtUserUpdateLayeredWindow( HWND hwnd, HDC hdc_dst, const POINT *pts_dst, const SIZE *size,
HDC hdc_src, const POINT *pts_src, COLORREF key,
const BLENDFUNCTION *blend, DWORD flags, const RECT *dirty );
BOOL WINAPI NtUserValidateRect( HWND hwnd, const RECT *rect );
WORD WINAPI NtUserVkKeyScanEx( WCHAR chr, HKL layout );
DWORD WINAPI NtUserWaitForInputIdle( HANDLE process, DWORD timeout, BOOL wow );
HWND WINAPI NtUserWindowFromDC( HDC hdc );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment