From: Julian Orth ju.orth@gmail.com
When opening the Cheat Engine [1] settings window, the window is spawned at around 400x400, making the right and bottom sides of the window inaccessible due to clipping. This commit moves the window to 0x0 to ensure that all window contents on the monitor are accessible.
[1]: https://github.com/cheat-engine/cheat-engine
Signed-off-by: Julian Orth ju.orth@gmail.com --- dlls/winewayland.drv/window.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/winewayland.drv/window.c b/dlls/winewayland.drv/window.c index acc34a18218..d5ae8f2d597 100644 --- a/dlls/winewayland.drv/window.c +++ b/dlls/winewayland.drv/window.c @@ -615,7 +615,7 @@ static void wayland_configure_window(HWND hwnd) if (needs_enter_size_move) send_message(hwnd, WM_ENTERSIZEMOVE, 0, 0); if (needs_exit_size_move) send_message(hwnd, WM_EXITSIZEMOVE, 0, 0);
- flags |= SWP_NOACTIVATE | SWP_NOZORDER | SWP_NOOWNERZORDER | SWP_NOMOVE; + flags |= SWP_NOACTIVATE | SWP_NOZORDER | SWP_NOOWNERZORDER; if (window_width == 0 || window_height == 0) flags |= SWP_NOSIZE;
style = NtUserGetWindowLongW(hwnd, GWL_STYLE); @@ -634,7 +634,10 @@ static void wayland_configure_window(HWND hwnd) }
SetRect(&rect, 0, 0, window_width, window_height); - OffsetRect(&rect, data->rects.window.left, data->rects.window.top); + rect = window_rect_from_visible(&data->rects, rect); + if (rect.left == data->rects.window.left && rect.top == data->rects.window.top) + flags |= SWP_NOMOVE; + NtUserSetRawWindowPos(hwnd, rect, flags, FALSE); }