gdk_event_unref (old_event);
}
-
- if (g_queue_get_length (&display->queued_events) == 1 &&
- g_queue_peek_head_link (&display->queued_events) == scrolls)
- {
- GdkFrameClock *clock = gdk_surface_get_frame_clock (surface);
- if (clock) /* might be NULL if surface was destroyed */
- gdk_frame_clock_request_phase (clock, GDK_FRAME_CLOCK_PHASE_FLUSH_EVENTS);
- }
}
static void
g_queue_delete_link (&display->queued_events, pending_motions);
pending_motions = next;
}
-
- if (g_queue_get_length (&display->queued_events) == 1 &&
- g_queue_peek_head_link (&display->queued_events) == pending_motions)
- {
- GdkFrameClock *clock = gdk_surface_get_frame_clock (pending_motion_surface);
- if (clock) /* might be NULL if surface was destroyed */
- gdk_frame_clock_request_phase (clock, GDK_FRAME_CLOCK_PHASE_FLUSH_EVENTS);
- }
}
void
GdkEvent *event,
gulong serial)
{
- GdkSurface *event_surface;
+ GdkSurface *event_surface = NULL;
gboolean unlink_event = FALSE;
GdkDeviceGrabInfo *button_release_grab;
GdkPointerSurfaceInfo *pointer_info = NULL;
*/
_gdk_event_queue_handle_motion_compression (display);
gdk_event_queue_handle_scroll_compression (display);
+
+ if (event_surface)
+ {
+ GdkFrameClock *clock = gdk_surface_get_frame_clock (event_surface);
+
+ if (clock) /* might be NULL if surface was destroyed */
+ gdk_frame_clock_request_phase (clock, GDK_FRAME_CLOCK_PHASE_FLUSH_EVENTS);
+ }
}
/**