win32u: Honor CS_HREDRAW and CS_VREDRAW when resizing window.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52903
This commit is contained in:
Jinoh Kang 2022-12-22 01:21:48 +09:00 committed by Alexandre Julliard
parent b2a9445e15
commit eb1f9896cc
2 changed files with 6 additions and 2 deletions

View file

@ -9475,7 +9475,6 @@ static void subtest_hvredraw(HWND hparent, const char *classname, DWORD style)
CombineRgn( hrgn_expect, hrgn_new_vis, hrgn_old_vis, is_redraw ? RGN_COPY : RGN_DIFF );
rgn_ok = EqualRgn( hrgn_expect, hrgn_actual );
todo_wine_if( is_redraw )
ok( !!rgn_ok, "Update region shall match expected region\n" );
if (!rgn_ok && winetest_debug > 1)

View file

@ -3116,6 +3116,7 @@ static UINT calc_ncsize( WINDOWPOS *winpos, const RECT *old_window_rect, const R
{
NCCALCSIZE_PARAMS params;
WINDOWPOS winposCopy;
UINT class_style;
params.rgrc[0] = *new_window_rect;
params.rgrc[1] = *old_window_rect;
@ -3135,7 +3136,11 @@ static UINT calc_ncsize( WINDOWPOS *winpos, const RECT *old_window_rect, const R
winposCopy.cy = old_window_rect->bottom - old_window_rect->top;
}
wvr_flags = send_message( winpos->hwnd, WM_NCCALCSIZE, TRUE, (LPARAM)&params );
class_style = get_class_long( winpos->hwnd, GCL_STYLE, FALSE );
if (class_style & CS_VREDRAW) wvr_flags |= WVR_VREDRAW;
if (class_style & CS_HREDRAW) wvr_flags |= WVR_HREDRAW;
wvr_flags |= send_message( winpos->hwnd, WM_NCCALCSIZE, TRUE, (LPARAM)&params );
*new_client_rect = params.rgrc[0];