[PATCH 0/1] MR3197: win32u: Update the display cache when virtual desktop mode changes.
We update the cache in NtUserCreateDesktopEx, as it may change existing thread desktop flags, but we need to do it as well when a new desktop is created while still detached, then attached to a thread through NtUserSetThreadDesktop. Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=55146 This is the case when forcing virtual desktop mode with new desktop creation by running `explorer /desktop=test,1024x768 winecfg` for instance. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/3197
From: Rémi Bernon <rbernon(a)codeweavers.com> We update the cache in NtUserCreateDesktopEx, as it may change existing thread desktop flags, but we need to do it as well when a new desktop is created while still detached, then attached to a thread through NtUserSetThreadDesktop. Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=55146 --- dlls/win32u/winstation.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dlls/win32u/winstation.c b/dlls/win32u/winstation.c index 9b97a4b4076..f99bef2bf11 100644 --- a/dlls/win32u/winstation.c +++ b/dlls/win32u/winstation.c @@ -248,7 +248,7 @@ HDESK WINAPI NtUserGetThreadDesktop( DWORD thread ) */ BOOL WINAPI NtUserSetThreadDesktop( HDESK handle ) { - BOOL ret; + BOOL ret, was_virtual_desktop = is_virtual_desktop(); SERVER_START_REQ( set_thread_desktop ) { @@ -264,6 +264,7 @@ BOOL WINAPI NtUserSetThreadDesktop( HDESK handle ) thread_info->client_info.top_window = 0; thread_info->client_info.msg_window = 0; if (key_state_info) key_state_info->time = 0; + if (was_virtual_desktop != is_virtual_desktop()) update_display_cache( TRUE ); } return ret; } -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/3197
participants (1)
-
Rémi Bernon