clutter: Drop _clutter_clear_events_queue_for_stage()

There's only one stage. Let's not overcomplicate things, as it
will not be possible to simply go through the event queue inspecting
every event.

https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403
This commit is contained in:
Carlos Garnacho 2020-08-11 19:30:17 +02:00
parent 034aff4306
commit 6f3ce4de24
2 changed files with 1 additions and 25 deletions

View File

@ -2297,30 +2297,6 @@ _clutter_clear_events_queue (void)
}
}
void
_clutter_clear_events_queue_for_stage (ClutterStage *stage)
{
ClutterMainContext *context = _clutter_context_get_default ();
GList *l, *next;
if (context->events_queue == NULL)
return;
/* Remove any pending events for this stage from the event queue */
for (l = context->events_queue->head; l; l = next)
{
ClutterEvent *event = l->data;
next = l->next;
if (event->any.stage == stage)
{
g_queue_delete_link (context->events_queue, l);
clutter_event_free (event);
}
}
}
ClutterPickMode
_clutter_context_get_pick_mode (void)
{

View File

@ -1660,7 +1660,7 @@ clutter_stage_dispose (GObject *object)
clutter_actor_hide (CLUTTER_ACTOR (object));
_clutter_clear_events_queue_for_stage (stage);
_clutter_clear_events_queue ();
if (priv->impl != NULL)
{