From 1e6c128c4cd84fc06795596c985e761e248da7c0 Mon Sep 17 00:00:00 2001 From: expikr <77922942+expikr@users.noreply.github.com> Date: Wed, 5 Jul 2023 11:35:20 +0800 Subject: [PATCH] Update SDL_windowswindow.c (cherry picked from commit d0fdf6207bf231eccc7f50ec8b98f6301bb6ce46) --- src/video/windows/SDL_windowswindow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video/windows/SDL_windowswindow.c b/src/video/windows/SDL_windowswindow.c index 1d128f7dda..3ea367ceef 100644 --- a/src/video/windows/SDL_windowswindow.c +++ b/src/video/windows/SDL_windowswindow.c @@ -1293,7 +1293,7 @@ void WIN_UpdateClipCursor(SDL_Window *window) (window->mouse_rect.w > 0 && window->mouse_rect.h > 0)) && (window->flags & SDL_WINDOW_INPUT_FOCUS)) { if (mouse->relative_mode && !mouse->relative_mode_warp && data->mouse_relative_mode_center) { - if (GetWindowRect(data->hwnd, &rect)) { + if (GetClientRect(data->hwnd, &rect)) { /* WIN_WarpCursor() jitters by +1, and remote desktop warp wobble is +/- 1 */ LONG remote_desktop_adjustment = GetSystemMetrics(SM_REMOTESESSION) ? 2 : 0; LONG cx, cy;