about summary refs log tree commit diff
path: root/exwm.el
diff options
context:
space:
mode:
authorChris Feng <chris.w.feng@gmail.com>2015-09-16T13·32+0800
committerChris Feng <chris.w.feng@gmail.com>2015-09-16T13·36+0800
commitb458d5ac30afed348df4788721bb48be94e97c60 (patch)
tree47a95d918c88d328fef4b67224abeb9b727d69ed /exwm.el
parent576a676f1f0895bd473d54c2713ee9e2423023e6 (diff)
Allow showing buffers on other workspaces and moving an X window by switching
to its buffer

* exwm-workspace.el (exwm-workspace-show-all-buffers, exwm-workspace-switch)
  (exwm-workspace-move-window, exwm-workspace-switch-to-buffer): Show buffers
  on other workspaces if `exwm-workspace-show-all-buffers' is non-nil.

* exwm-layout.el (exwm-layout-show-all-buffers, exwm-layout--refresh): Allow
  moving an X window by switch to its corresponding buffer from another
  workspace when `exwm-layout-show-all-buffers' is non-nil.
* exwm.el (exwm--ido-buffer-window-other-frame): Handle the case when
  `exwm-layout-show-all-buffers' is non-nil.

* exwm-floating.el (exwm-floating--set-floating): Handle the case when
  *scratch* buffer is killed.

* exwm-workspace.el (exwm-workspace-switch-to-buffer): Renamed from
  `exwm-workspace-switch-to-window' to better reflect its role.
Diffstat (limited to 'exwm.el')
-rw-r--r--exwm.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/exwm.el b/exwm.el
index bf45e40c8b5d..9311af1c8d13 100644
--- a/exwm.el
+++ b/exwm.el
@@ -538,7 +538,9 @@
 (defun exwm--ido-buffer-window-other-frame (orig-fun buffer)
   "Wrapper for `ido-buffer-window-other-frame' to exclude invisible windows."
   (with-current-buffer buffer
-    (if (eq major-mode 'exwm-mode)
+    (if (and (eq major-mode 'exwm-mode)
+             (or exwm--floating-frame
+                 (not exwm-layout-show-all-buffers)))
         ;; `ido-mode' works well with `exwm-mode' buffers
         (funcall orig-fun buffer)
       ;; Other buffers should be selected within the same workspace