Fixed relative mouse motion moving farther and farther off screen.
1.1 --- a/src/events/SDL_mouse.c Sat Mar 28 00:48:03 2015 -0400
1.2 +++ b/src/events/SDL_mouse.c Mon Mar 30 11:31:53 2015 -0700
1.3 @@ -293,9 +293,14 @@
1.4 event.motion.yrel = yrel;
1.5 posted = (SDL_PushEvent(&event) > 0);
1.6 }
1.7 - /* Use unclamped values if we're getting events outside the window */
1.8 - mouse->last_x = x;
1.9 - mouse->last_y = y;
1.10 + if (relative) {
1.11 + mouse->last_x = mouse->x;
1.12 + mouse->last_y = mouse->y;
1.13 + } else {
1.14 + /* Use unclamped values if we're getting events outside the window */
1.15 + mouse->last_x = x;
1.16 + mouse->last_y = y;
1.17 + }
1.18 return posted;
1.19 }
1.20