summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Garnacho <carlosg@gnome.org>2014-06-25 13:14:44 +0200
committerEmmanuele Bassi <ebassi@gnome.org>2014-06-25 16:55:41 +0100
commit02590f08ac81a24c476fdf18d79ceffdfe7f1a34 (patch)
treeec7aac0bb3dded38ab1a86d11fdfd35c44fba6a9
parent4c4e72a9dc3674774a8d38054a4bb8b95fdd972b (diff)
downloadclutter-02590f08ac81a24c476fdf18d79ceffdfe7f1a34.tar.gz
gesture-action: Ignore any other event than press/update/release ones
CLUTTER_ENTER/LEAVE might be processed too, leading to accounting of the NULL sequence (ie. pointer) in the gesture, and fooling the gesture with a static extra point that wouldn't go away. https://bugzilla.gnome.org/show_bug.cgi?id=732235
-rw-r--r--clutter/clutter-gesture-action.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/clutter/clutter-gesture-action.c b/clutter/clutter-gesture-action.c
index 6902d771d..90c803226 100644
--- a/clutter/clutter-gesture-action.c
+++ b/clutter/clutter-gesture-action.c
@@ -363,6 +363,11 @@ stage_captured_event_cb (ClutterActor *stage,
gboolean return_value;
GesturePoint *point;
+ if (event->type != CLUTTER_TOUCH_CANCEL &&
+ event->type != CLUTTER_TOUCH_UPDATE && event->type != CLUTTER_TOUCH_END &&
+ event->type != CLUTTER_MOTION && event->type != CLUTTER_BUTTON_RELEASE)
+ return CLUTTER_EVENT_PROPAGATE;
+
if ((point = gesture_find_point (action, event, &position)) == NULL)
return CLUTTER_EVENT_PROPAGATE;