altTab: Allow pressing uppercase keys to close apps and windows
Right now only pressing "w" and "q" will close a window or an app, don't confuse people who have caps-lock enabled or are holding down shift. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/168
This commit is contained in:
parent
84250bbf88
commit
efd6be60e3
@ -175,7 +175,7 @@ class AppSwitcherPopup extends SwitcherPopup.SwitcherPopup {
|
|||||||
this._select(this._next());
|
this._select(this._next());
|
||||||
} else if (action == Meta.KeyBindingAction.SWITCH_APPLICATIONS_BACKWARD) {
|
} else if (action == Meta.KeyBindingAction.SWITCH_APPLICATIONS_BACKWARD) {
|
||||||
this._select(this._previous());
|
this._select(this._previous());
|
||||||
} else if (keysym === Clutter.KEY_q) {
|
} else if (keysym == Clutter.KEY_q || keysym === Clutter.KEY_Q) {
|
||||||
this._quitApplication(this._selectedIndex);
|
this._quitApplication(this._selectedIndex);
|
||||||
} else if (this._thumbnailsFocused) {
|
} else if (this._thumbnailsFocused) {
|
||||||
if (keysym === Clutter.KEY_Left)
|
if (keysym === Clutter.KEY_Left)
|
||||||
@ -184,7 +184,7 @@ class AppSwitcherPopup extends SwitcherPopup.SwitcherPopup {
|
|||||||
this._select(this._selectedIndex, this._nextWindow());
|
this._select(this._selectedIndex, this._nextWindow());
|
||||||
else if (keysym === Clutter.KEY_Up)
|
else if (keysym === Clutter.KEY_Up)
|
||||||
this._select(this._selectedIndex, null, true);
|
this._select(this._selectedIndex, null, true);
|
||||||
else if (keysym === Clutter.KEY_w || keysym === Clutter.KEY_F4)
|
else if (keysym === Clutter.KEY_w || keysym === Clutter.KEY_W || keysym === Clutter.KEY_F4)
|
||||||
this._closeAppWindow(this._selectedIndex, this._currentWindow);
|
this._closeAppWindow(this._selectedIndex, this._currentWindow);
|
||||||
else
|
else
|
||||||
return Clutter.EVENT_PROPAGATE;
|
return Clutter.EVENT_PROPAGATE;
|
||||||
@ -587,7 +587,7 @@ class WindowSwitcherPopup extends SwitcherPopup.SwitcherPopup {
|
|||||||
this._select(this._previous());
|
this._select(this._previous());
|
||||||
else if (keysym == Clutter.KEY_Right)
|
else if (keysym == Clutter.KEY_Right)
|
||||||
this._select(this._next());
|
this._select(this._next());
|
||||||
else if (keysym == Clutter.KEY_w || keysym == Clutter.KEY_F4)
|
else if (keysym === Clutter.KEY_w || keysym === Clutter.KEY_W || keysym === Clutter.KEY_F4)
|
||||||
this._closeWindow(this._selectedIndex);
|
this._closeWindow(this._selectedIndex);
|
||||||
else
|
else
|
||||||
return Clutter.EVENT_PROPAGATE;
|
return Clutter.EVENT_PROPAGATE;
|
||||||
|
Loading…
Reference in New Issue
Block a user