projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
added fields to graphics info structure to store current mouse position
[rocksndiamonds.git]
/
src
/
events.c
diff --git
a/src/events.c
b/src/events.c
index 8279f70fb223bba859d2203823528650d7b40ef4..52595e2512fd177b4127a1bd4af4b3cf13579275 100644
(file)
--- a/
src/events.c
+++ b/
src/events.c
@@
-74,6
+74,9
@@
static int FilterEvents(const Event *event)
{
((MotionEvent *)event)->x -= video.screen_xoffset;
((MotionEvent *)event)->y -= video.screen_yoffset;
{
((MotionEvent *)event)->x -= video.screen_xoffset;
((MotionEvent *)event)->y -= video.screen_yoffset;
+
+ gfx.mouse_x = ((MotionEvent *)event)->x;
+ gfx.mouse_y = ((MotionEvent *)event)->y;
}
// non-motion events are directly passed to event handler functions
}
// non-motion events are directly passed to event handler functions
@@
-1016,6
+1019,8
@@
void HandleFingerEvent(FingerEvent *event)
event->pressure);
#endif
event->pressure);
#endif
+ runtime.uses_touch_device = TRUE;
+
if (game_status != GAME_MODE_PLAYING)
return;
if (game_status != GAME_MODE_PLAYING)
return;