From 848c566d507968f80b42a99f68b881c3d471fd27 Mon Sep 17 00:00:00 2001 From: Paweł Kołodziejski Date: Sat, 29 Mar 2003 09:56:51 +0000 Subject: fix for wrong(or rather unset) mouse 0,0 (x,y) position when joystick is plugged when code handle joystick motion and mapping to mouse motion, it should also set mouse x,y position svn-id: r6880 --- backends/sdl/sdl-common.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'backends/sdl') diff --git a/backends/sdl/sdl-common.cpp b/backends/sdl/sdl-common.cpp index 14ef88b4e7..c5905da384 100644 --- a/backends/sdl/sdl-common.cpp +++ b/backends/sdl/sdl-common.cpp @@ -780,6 +780,10 @@ bool OSystem_SDL_Common::poll_event(Event *event) { } #endif } + event->mouse.x = km.x; + event->mouse.y = km.y; + event->mouse.x /= _scaleFactor; + event->mouse.y /= _scaleFactor; return true; case SDL_VIDEOEXPOSE: -- cgit v1.2.3