Commit 8892b791 authored by Zhiyi Zhang's avatar Zhiyi Zhang Committed by Alexandre Julliard

user32: Change the position and size of layered windows before flushing their surfaces.

When UpdateLayeredWindow() is called to paint a window and update its size, USER_Driver->pUpdateLayeredWindow() needs to be called after the window position and size are updated. Otherwise, UpdateLayeredWindow() may flush the painted content to a smaller window and then enlarge it, losing the painted result. Fix Word 2016 window frame corruption after restoring from maximized state. Signed-off-by: 's avatarZhiyi Zhang <zzhang@codeweavers.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent e45d51fd
......@@ -4134,10 +4134,8 @@ BOOL WINAPI UpdateLayeredWindowIndirect( HWND hwnd, const UPDATELAYEREDWINDOWINF
TRACE( "window %p win %s client %s\n", hwnd,
wine_dbgstr_rect(&window_rect), wine_dbgstr_rect(&client_rect) );
if (!USER_Driver->pUpdateLayeredWindow( hwnd, info, &window_rect )) return FALSE;
set_window_pos( hwnd, 0, flags, &window_rect, &client_rect, NULL );
return TRUE;
return USER_Driver->pUpdateLayeredWindow( hwnd, info, &window_rect );
}
......
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