diff options
| author | Chong Yidong <cyd@gnu.org> | 2012-08-06 13:33:39 +0800 |
|---|---|---|
| committer | Chong Yidong <cyd@gnu.org> | 2012-08-06 13:33:39 +0800 |
| commit | 90749b537a83a3ba623e6f6163256130575fac2f (patch) | |
| tree | 75342f636beeed8c355fe4e4ad31ca80830a40b7 /lisp/replace.el | |
| parent | edd74c35125983cbf822b15828886c7d2e50b275 (diff) | |
| download | emacs-90749b537a83a3ba623e6f6163256130575fac2f.tar.gz | |
Add inhibit-switch-frame parameter for display-buffer, and use it in occur-edit.
* replace.el (occur-after-change-function): Avoid losing focus by
using the inhibit-switch-frame display action option.
* window.el (window--maybe-raise-frame): New function.
(window--display-buffer): Split off from here.
(display-buffer-reuse-window, display-buffer-pop-up-frame)
(display-buffer-pop-up-window, display-buffer-use-some-window):
Obey an inhibit-switch-frame action alist entry.
(display-buffer): Update doc.
Fixes: debbugs:12139
Diffstat (limited to 'lisp/replace.el')
| -rw-r--r-- | lisp/replace.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/replace.el b/lisp/replace.el index fecdb35fcaf..3373ee8e512 100644 --- a/lisp/replace.el +++ b/lisp/replace.el @@ -912,7 +912,9 @@ To return to ordinary Occur mode, use \\[occur-cease-edit]." (line-number-at-pos (window-start)))) (readonly (with-current-buffer buf buffer-read-only)) (win (or (get-buffer-window buf) - (display-buffer buf t))) + (display-buffer buf + '(nil (inhibit-same-window . t) + (inhibit-switch-frame . t))))) (line-end (line-end-position)) (text (save-excursion (goto-char (next-single-property-change |
