about summary refs log tree commit diff
path: root/exwm-manage.el
diff options
context:
space:
mode:
authorChris Feng <chris.w.feng@gmail.com>2015-08-07T12·22+0800
committerChris Feng <chris.w.feng@gmail.com>2015-08-07T12·22+0800
commit84f0f0328b173af82c873e395353bd9a6c3bf1f6 (patch)
tree38c8c7ed82b9f67ff4b854cd6a71f8b7f369461f /exwm-manage.el
parent2ad1a89db0c9e3704c79294620c5ed4925b143eb (diff)
Fix input focus lost after closing window
Also insert some debug messages.
Diffstat (limited to 'exwm-manage.el')
-rw-r--r--exwm-manage.el6
1 files changed, 4 insertions, 2 deletions
diff --git a/exwm-manage.el b/exwm-manage.el
index 0d2c74f4f16f..7c82696fb7f2 100644
--- a/exwm-manage.el
+++ b/exwm-manage.el
@@ -178,8 +178,10 @@ corresponding buffer.")
                              :window id :property xcb:Atom:WM_STATE))
           (xcb:flush exwm--connection))
         (setq kill-buffer-query-functions nil)
-        (kill-buffer)
-        (select-frame-set-input-focus exwm-workspace--current)))))
+        (let ((floating exwm--floating-frame))
+          (kill-buffer)
+          (when floating
+            (select-frame-set-input-focus exwm-workspace--current)))))))
 
 (defun exwm-manage--scan ()
   "Search for existing windows and try to manage them."