about summary refs log tree commit diff
path: root/exwm-layout.el
diff options
context:
space:
mode:
authorAdrián Medraño Calvo <adrian@medranocalvo.com>2018-08-30T12·00+0000
committerAdrián Medraño Calvo <adrian@medranocalvo.com>2018-08-30T12·00+0000
commit5f6b866cfed7214caabd5f5dd0f952cce93a307c (patch)
tree9150ba640054fda72bd748b6b31f7fae076c6778 /exwm-layout.el
parent2b1ed2ce704de5b61391f34251c89e5187c4a593 (diff)
Refresh layout after activating/deactivating workspaces
* exwm-workspace.el (exwm-workspace--set-active): Refresh layout
after activating or deactivating workspaces.

* exwm-layout.el (exwm-layout--refresh-workspace): Hide X windows on
inactive workspaces.
Diffstat (limited to 'exwm-layout.el')
-rw-r--r--exwm-layout.el7
1 files changed, 4 insertions, 3 deletions
diff --git a/exwm-layout.el b/exwm-layout.el
index 09a34985a7c6..56faadd99209 100644
--- a/exwm-layout.el
+++ b/exwm-layout.el
@@ -320,9 +320,10 @@ selected by `other-buffer'."
                   (exwm-layout--hide exwm--id))
               (let ((window (car windows)))
                 (if (eq frame exwm--frame)
-                    (when (exwm-workspace--active-p frame)
-                      ;; Show it if `frame' is active.
-                      (exwm-layout--show exwm--id window))
+                    ;; Show it if `frame' is active, hide otherwise.
+                    (if (exwm-workspace--active-p frame)
+                        (exwm-layout--show exwm--id window)
+                      (exwm-layout--hide exwm--id))
                   ;; It was last shown in other workspace; move it here.
                   (exwm-workspace-move-window frame exwm--id))
                 ;; Vacate any other windows (in any workspace) showing this