diff options
author | Jan-Michael Brummer <jan.brummer@tabos.org> | 2017-03-30 19:05:06 +0200 |
---|---|---|
committer | Jiří Techet <techet@gmail.com> | 2017-03-23 02:06:28 +0100 |
commit | b76777f31ce4a1a550aebac6e18b3371a81d6cb4 (patch) | |
tree | 8bf30d6939bc10e0f1cbef38278974580c82c69a | |
parent | 18bd89d5e4ecebe634ff4aba9eabc9a78ecbf10a (diff) | |
download | libchamplain-b76777f31ce4a1a550aebac6e18b3371a81d6cb4.tar.gz |
Fix touch gesture zoom
Check the source device instead of the master to differentiate between pointer and touch device.
-rw-r--r-- | champlain/champlain-view.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/champlain/champlain-view.c b/champlain/champlain-view.c index 709e029..784d644 100644 --- a/champlain/champlain-view.c +++ b/champlain/champlain-view.c @@ -1455,7 +1455,8 @@ zoom_gesture_begin_cb (ClutterGestureAction *gesture, G_GNUC_UNUSED ClutterActor *actor, G_GNUC_UNUSED gpointer user_data) { - ClutterInputDevice *device = clutter_gesture_action_get_device (gesture, 0); + ClutterEvent *event = clutter_gesture_action_get_last_event (gesture, 0); + ClutterInputDevice *device = clutter_event_get_source_device (event); /* Give up on >2 finger input and when using mouse */ return clutter_gesture_action_get_n_current_points (gesture) == 2 && |