Explorar o código

Apply DPI scale to mouse coordinates in SDL_WarpMouseInWindow()

Fixes https://github.com/libsdl-org/SDL/issues/7855
Sam Lantinga %!s(int64=2) %!d(string=hai) anos
pai
achega
657c346556
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      src/video/windows/SDL_windowsmouse.c

+ 1 - 0
src/video/windows/SDL_windowsmouse.c

@@ -288,6 +288,7 @@ static void WIN_WarpMouse(SDL_Window *window, int x, int y)
         return;
     }
 
+    WIN_ClientPointFromSDL(window, &x, &y);
     pt.x = x;
     pt.y = y;
     ClientToScreen(hwnd, &pt);