gesture: Skip non-device events early.

This commit is contained in:
Carlos Garnacho 2014-03-21 17:17:42 +01:00
parent 25ece22013
commit d2c9b9c2aa

View File

@ -322,8 +322,14 @@ gtk_gesture_handle_event (GtkEventController *controller,
GtkGesture *gesture = GTK_GESTURE (controller);
GdkEventSequence *sequence;
GtkGesturePrivate *priv;
GdkDevice *source_device;
gboolean was_recognized;
source_device = gdk_event_get_source_device (event);
if (!source_device)
return FALSE;
priv = gtk_gesture_get_instance_private (gesture);
sequence = gdk_event_get_event_sequence (event);
priv->last_sequence = sequence;