altTab: Don't activate an app it the icon is no longer available

https://bugzilla.gnome.org/show_bug.cgi?id=620106
This commit is contained in:
Mario Sanchez Prada 2017-11-30 20:53:39 +00:00
parent e608d4f26b
commit 815302b4ac

View File

@ -254,11 +254,12 @@ var AppSwitcherPopup = new Lang.Class({
_finish : function(timestamp) {
let appIcon = this._items[this._selectedIndex];
if (appIcon) {
if (this._currentWindow < 0)
appIcon.app.activate_window(appIcon.cachedWindows[0], timestamp);
else if (appIcon.cachedWindows[this._currentWindow])
Main.activateWindow(appIcon.cachedWindows[this._currentWindow], timestamp);
}
this.parent();
},