Zhiyi Zhang : user32: Change the position and size of layered windows before flushing their surfaces.
Alexandre Julliard
julliard at winehq.org
Wed Oct 20 15:58:39 CDT 2021
Module: wine
Branch: master
Commit: 8892b79118fde5f2307ecbbdb03a8d0c489c8b3d
URL: https://source.winehq.org/git/wine.git/?a=commit;h=8892b79118fde5f2307ecbbdb03a8d0c489c8b3d
Author: Zhiyi Zhang <zzhang at codeweavers.com>
Date: Wed Oct 20 10:07:59 2021 +0800
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: Zhiyi Zhang <zzhang at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/user32/win.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/dlls/user32/win.c b/dlls/user32/win.c
index e07b7d39e4b..4d0240f21a8 100644
--- a/dlls/user32/win.c
+++ b/dlls/user32/win.c
@@ -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 );
}
More information about the wine-cvs
mailing list