click-action: Ignore motions/updates from different devices/sequences

Otherwise events from other devices or touch sequences might unintendedly
trigger the thresholds, and a "cancelled" ::long-press with it.

https://bugzilla.gnome.org/show_bug.cgi?id=756749
This commit is contained in:
Carlos Garnacho 2015-10-16 19:07:19 +02:00
parent 9ea14ff949
commit 9753c99382

View File

@ -414,6 +414,10 @@ on_captured_event (ClutterActor *stage,
gfloat motion_x, motion_y;
gfloat delta_x, delta_y;
if (clutter_event_get_device_id (event) != priv->press_device_id ||
clutter_event_get_event_sequence (event) != priv->press_sequence)
return CLUTTER_EVENT_PROPAGATE;
if (!priv->is_held)
return CLUTTER_EVENT_PROPAGATE;