Fix warning with event compression on a destroyed window

Fix a critical message when we try to compress events for a window
that was already destroyed.
This commit is contained in:
Owen W. Taylor 2013-11-11 18:17:38 -05:00
parent aaecf7d826
commit fbfeb00545

View File

@ -316,6 +316,7 @@ _gdk_event_queue_handle_motion_compression (GdkDisplay *display)
pending_motions == display->queued_tail)
{
GdkFrameClock *clock = gdk_window_get_frame_clock (pending_motion_window);
if (clock) /* might be NULL if window was destroyed */
gdk_frame_clock_request_phase (clock, GDK_FRAME_CLOCK_PHASE_FLUSH_EVENTS);
}
}