about summary refs log tree commit diff
path: root/exwm-layout.el
diff options
context:
space:
mode:
Diffstat (limited to 'exwm-layout.el')
-rw-r--r--exwm-layout.el15
1 files changed, 14 insertions, 1 deletions
diff --git a/exwm-layout.el b/exwm-layout.el
index a14651a46df9..ae1f48de8f86 100644
--- a/exwm-layout.el
+++ b/exwm-layout.el
@@ -239,7 +239,20 @@
         (with-current-buffer (window-buffer window)
           (when (and (eq major-mode 'exwm-mode)
                      (or exwm--floating-frame (not (eq frame exwm--frame))))
-            (set-window-buffer window placeholder)))))))
+            (set-window-buffer window placeholder))))
+      ;; Update _NET_CLIENT_LIST_STACKING
+      (xcb:+request exwm--connection
+          (make-instance 'xcb:ewmh:set-_NET_CLIENT_LIST_STACKING
+                         :window exwm--root
+                         :data (vconcat
+                                (delq nil
+                                      (mapcar
+                                       (lambda (buffer)
+                                         (with-current-buffer buffer
+                                           (when (eq major-mode 'exwm-mode)
+                                             exwm--id)))
+                                       (buffer-list))))))
+      (xcb:flush exwm--connection))))
 
 (defun exwm-layout--on-minibuffer-setup ()
   "Refresh layout when minibuffer grows."