From: Alexandros Frantzis alexandros.frantzis@collabora.com
Since changes in a parent window state may affect the children state in the driver, ensure the driver gets a chance to update its internal state. --- dlls/win32u/window.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+)
diff --git a/dlls/win32u/window.c b/dlls/win32u/window.c index 73478438928..e34a1a296fd 100644 --- a/dlls/win32u/window.c +++ b/dlls/win32u/window.c @@ -3517,6 +3517,8 @@ done: return after; }
+static void update_children_window_state( HWND hwnd ); + /* NtUserSetWindowPos implementation */ BOOL set_window_pos( WINDOWPOS *winpos, int parent_x, int parent_y ) { @@ -3653,6 +3655,8 @@ BOOL set_window_pos( WINDOWPOS *winpos, int parent_x, int parent_y ) if ((winpos->flags & (SWP_NOSIZE|SWP_NOMOVE|SWP_FRAMECHANGED)) != (SWP_NOSIZE|SWP_NOMOVE)) NtUserNotifyWinEvent( EVENT_OBJECT_LOCATIONCHANGE, winpos->hwnd, OBJID_WINDOW, 0 );
+ update_children_window_state( winpos->hwnd ); + ret = TRUE; done: set_thread_dpi_awareness_context( context ); @@ -4386,6 +4390,23 @@ void update_window_state( HWND hwnd ) if (surface) window_surface_release( surface );
set_thread_dpi_awareness_context( context ); + + update_children_window_state( hwnd ); +} + +static void update_children_window_state( HWND hwnd ) +{ + HWND *children; + int i; + + if (!(children = list_window_children( 0, hwnd, NULL, 0 ))) return; + + for (i = 0; children[i]; i++) + { + if (is_window( children[i] )) update_window_state( children[i] ); + } + + free( children ); }
/***********************************************************************