From 263d9c4daec47c8fde3d5ead96a7212394514540 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Thu, 29 Dec 2011 04:24:15 -0500 Subject: [PATCH] Fixed bug 1032 Matthias Hawran 2010-07-28 03:00:49 PDT Hi, I simply want to "forward" this post (http://forums.libsdl.org/viewtopic.php?t=4123) about absolute mouse events not being monitored by SDL 1.2 as directfb / tslib generates them. It's fixed in 1.3 and IMHO it should be backported to 1.2 Included the patch from the post (thanks to Guillaume Chereau) Cheers, Matthias --- src/video/directfb/SDL_DirectFB_events.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/video/directfb/SDL_DirectFB_events.c b/src/video/directfb/SDL_DirectFB_events.c index b0e12ee2b..987397614 100644 --- a/src/video/directfb/SDL_DirectFB_events.c +++ b/src/video/directfb/SDL_DirectFB_events.c @@ -79,6 +79,15 @@ void DirectFB_PumpEvents (_THIS) else if (evt.axis == DIAI_Y) posted += SDL_PrivateMouseMotion(0, 1, 0, evt.axisrel); } + else if (evt.flags & DIEF_AXISABS) + { + static int last_x, last_y; + if (evt.axis == DIAI_X) + last_x = evt.axisabs; + else if (evt.axis == DIAI_Y) + last_y = evt.axisabs; + posted += SDL_PrivateMouseMotion(0, 0, last_x, last_y); + } break; default: ;