swipeTracker: Set up TouchSwipeGesture in the capture phase

Use the new API to specify the gesture phase.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1992>
This commit is contained in:
Carlos Garnacho 2021-09-27 22:44:37 +02:00
parent 919c4cf3d5
commit 748fe074c4

View File

@ -493,7 +493,7 @@ var SwipeTracker = GObject.registerClass({
this.bind_property('orientation', this._touchGesture, 'orientation',
GObject.BindingFlags.SYNC_CREATE);
this.bind_property('distance', this._touchGesture, 'distance', 0);
global.stage.add_action(this._touchGesture);
global.stage.add_action_full('swipe', Clutter.EventPhase.CAPTURE, this._touchGesture);
if (params.allowDrag) {
this._dragGesture = new TouchSwipeGesture(allowedModes, 1,