chiark / gitweb /
el/dot-emacs.el: Try again to prevent switching to windows in other frames.
authorMark Wooding <mdw@distorted.org.uk>
Wed, 9 Oct 2019 16:24:08 +0000 (17:24 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Fri, 8 Nov 2019 12:04:10 +0000 (12:04 +0000)
Ian Jackson pointed out that my previous countermeasure wasn't working.
I now have some new scars from `display-buffer'.

el/dot-emacs.el

index cb19d10f0a17313c502895964f28e14bd3156327..63b3c24e9b16438b31dcb9d9ab1be4a2de0230d3 100644 (file)
@@ -546,6 +546,11 @@ (defvar mdw-inhibit-walk-windows nil
 This is used by advice on `switch-to-buffer-other-frame' to inhibit finding
 buffers in random frames.")
 
+(setq display-buffer--other-frame-action
+      '((display-buffer-reuse-window display-buffer-pop-up-frame)
+       (reusable-frames . nil)
+       (inhibit-same-window . t)))
+
 (defadvice walk-windows (around mdw-inhibit activate)
   "If `mdw-inhibit-walk-windows' is non-nil, then do nothing."
   (and (not mdw-inhibit-walk-windows)