workspacesView: Adapt to changes in windowManager
The actionMoveWorkspace() function was changed in commit 8727661c1, adapt its use in workspacesView as well. https://bugzilla.gnome.org/show_bug.cgi?id=659288
This commit is contained in:
parent
d0310bd745
commit
e0a6a623d2
@ -760,15 +760,20 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
_onScrollEvent: function(actor, event) {
|
_onScrollEvent: function(actor, event) {
|
||||||
if (!this.actor.mapped)
|
if (!this.actor.mapped)
|
||||||
return false;
|
return false;
|
||||||
|
let activeWs = global.screen.get_active_workspace();
|
||||||
|
let ws;
|
||||||
switch (event.get_scroll_direction()) {
|
switch (event.get_scroll_direction()) {
|
||||||
case Clutter.ScrollDirection.UP:
|
case Clutter.ScrollDirection.UP:
|
||||||
Main.wm.actionMoveWorkspace(Meta.MotionDirection.UP);
|
ws = activeWs.get_neighbor(Meta.MotionDirection.UP);
|
||||||
return true;
|
break;
|
||||||
case Clutter.ScrollDirection.DOWN:
|
case Clutter.ScrollDirection.DOWN:
|
||||||
Main.wm.actionMoveWorkspace(Meta.MotionDirection.DOWN);
|
ws = activeWs.get_neighbor(Meta.MotionDirection.DOWN);
|
||||||
return true;
|
break;
|
||||||
|
default:
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
return false;
|
Main.wm.actionMoveWorkspace(ws);
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Signals.addSignalMethods(WorkspacesDisplay.prototype);
|
Signals.addSignalMethods(WorkspacesDisplay.prototype);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user