swipeTracker: Pass orientation in constructor
When this class was written, all swipes in the shell were vertical, so it made sense to make the default orientation vertical. This isn't the case anymore, thus pass make it mandatory to specify orientation when creating a tracker. Change the property default values to horizontal as well to match Clutter instead of the old shell design. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1731>
This commit is contained in:

committed by
Marge Bot

parent
c06bc74d6d
commit
df4c05f834
@ -284,7 +284,9 @@ var WorkspaceAnimationController = class {
|
||||
});
|
||||
|
||||
const swipeTracker = new SwipeTracker.SwipeTracker(global.stage,
|
||||
Shell.ActionMode.NORMAL, { allowDrag: false });
|
||||
Clutter.Orientation.HORIZONTAL,
|
||||
Shell.ActionMode.NORMAL,
|
||||
{ allowDrag: false });
|
||||
swipeTracker.connect('begin', this._switchWorkspaceBegin.bind(this));
|
||||
swipeTracker.connect('update', this._switchWorkspaceUpdate.bind(this));
|
||||
swipeTracker.connect('end', this._switchWorkspaceEnd.bind(this));
|
||||
|
Reference in New Issue
Block a user