+ if (event->type == EVENT_BUTTONPRESS ||
+ event->type == EVENT_BUTTONRELEASE ||
+ event->type == EVENT_MOTIONNOTIFY)
+ {
+ // do not reset mouse cursor before all pending events have been processed
+ if (gfx.cursor_mode == cursor_mode_last &&
+ ((game_status == GAME_MODE_TITLE &&
+ gfx.cursor_mode == CURSOR_NONE) ||
+ (game_status == GAME_MODE_PLAYING &&
+ gfx.cursor_mode == CURSOR_PLAYFIELD)))
+ {
+ SetMouseCursor(CURSOR_DEFAULT);
+
+ DelayReached(&special_cursor_delay, 0);
+
+ cursor_mode_last = CURSOR_DEFAULT;
+ }
+ }
+