[gnome-shell/wip/msanchez/620106: 2/2] fixups



commit 9ef9c8d34f5f4ec9b96368ca4af1c8a7228492c1
Author: Mario Sanchez Prada <mario endlessm com>
Date:   Thu Nov 30 20:53:39 2017 +0000

    fixups

 js/ui/altTab.js |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)
---
diff --git a/js/ui/altTab.js b/js/ui/altTab.js
index 1a22afb..2626cd2 100644
--- a/js/ui/altTab.js
+++ b/js/ui/altTab.js
@@ -254,11 +254,12 @@ var AppSwitcherPopup = new Lang.Class({
 
     _finish : function(timestamp) {
         let appIcon = this._items[this._selectedIndex];
-        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);
-
+        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();
     },
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]