Don't activate workspace when more than one window is open
Currently clicking on an empty spot on the workspace actors switches to the workspace, this has a side effect that when for some reason (like using a touchpad), the user misses the window he intends to open he will end up with the currently focused window instead. Disable this behaviour if more than one window is open (in that case the user has to explicitly target a specific window). https://bugzilla.gnome.org/show_bug.cgi?id=610868
This commit is contained in:
parent
e752193a54
commit
2016e08f7b
@ -639,8 +639,13 @@ Workspace.prototype = {
|
||||
this._desktop.connect('selected',
|
||||
Lang.bind(this,
|
||||
function(clone, time) {
|
||||
this._metaWorkspace.activate(time);
|
||||
Main.overview.hide();
|
||||
// Only switch to the workspace when one window is open
|
||||
// We check for "2" here because the Desktop does not really count
|
||||
// as a window in this context.
|
||||
if (this._windows.length <= 2) {
|
||||
this._metaWorkspace.activate(time);
|
||||
Main.overview.hide();
|
||||
}
|
||||
}));
|
||||
this.actor.add_actor(this._desktop.actor);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user