[gnome-shell/T27795: 81/138] Show the desktop when minimizing or closing the last application



commit 8db5363ffbd922a8b6ae60f8fe89a125a8b60fe7
Author: Mario Sanchez Prada <mario endlessm com>
Date:   Wed Sep 13 12:53:45 2017 +0100

    Show the desktop when minimizing or closing the last application
    
    This makes sure we call showApps() when the last window dissapears.

 js/ui/workspaceMonitor.js | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)
---
diff --git a/js/ui/workspaceMonitor.js b/js/ui/workspaceMonitor.js
index 8fa667fe40..0e8b77cdd4 100644
--- a/js/ui/workspaceMonitor.js
+++ b/js/ui/workspaceMonitor.js
@@ -34,8 +34,17 @@ var WorkspaceMonitor = class {
 
     _updateOverview() {
         let visibleApps = this._getVisibleApps();
-        if (visibleApps.length != 0 && this._inFullscreen)
+        if (visibleApps.length == 0) {
+            // Even if no apps are visible, if there is an app starting up, we
+            // do not show the overview as it's likely that a window will be
+            // shown. This avoids problems of windows being mapped while the
+            // overview is being shown.
+            if (!this._appSystem.has_starting_apps())
+                Main.overview.showApps();
+        } else if (this._inFullscreen) {
+            // Hide in fullscreen mode
             Main.overview.hide();
+        }
     }
 
     _windowDisappeared(shellwm, actor) {


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