aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
authorMartin Rudalics2010-06-07 21:28:02 +0300
committerJuri Linkov2010-06-07 21:28:02 +0300
commit13b5221f4df08dd203b36cc444aab7e825dd29f8 (patch)
tree2cd4b4012752a3d6950b22a6b23e8b70858fa6bd /lisp
parent5220357f5856b5b917e84bb6f745982df05a9684 (diff)
downloademacs-13b5221f4df08dd203b36cc444aab7e825dd29f8.tar.gz
emacs-13b5221f4df08dd203b36cc444aab7e825dd29f8.zip
* window.el (pop-to-buffer): Remove the conditional that
compares new-window and old-window, so it will reselect the selected window unconditionally. http://lists.gnu.org/archive/html/emacs-devel/2010-06/msg00078.html * window.c (Fselect_window): Move `record_buffer' up to the beginning of this function, so the buffer gets recorded even if the selected window does not change. http://lists.gnu.org/archive/html/emacs-devel/2010-06/msg00137.html
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog7
-rw-r--r--lisp/window.el15
2 files changed, 13 insertions, 9 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 12de400ce07..04d914422e7 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,10 @@
12010-06-07 Martin Rudalics <rudalics@gmx.at>
2
3 * window.el (pop-to-buffer): Remove the conditional that
4 compares new-window and old-window, so it will reselect
5 the selected window unconditionally.
6 http://lists.gnu.org/archive/html/emacs-devel/2010-06/msg00078.html
7
12010-06-07 Stefan Monnier <monnier@iro.umontreal.ca> 82010-06-07 Stefan Monnier <monnier@iro.umontreal.ca>
2 9
3 * emacs-lisp/smie.el (smie-indent-offset-after) 10 * emacs-lisp/smie.el (smie-indent-offset-after)
diff --git a/lisp/window.el b/lisp/window.el
index eb8bedcc9e8..b674b480025 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -1220,19 +1220,16 @@ at the front of the list of recently selected ones."
1220 (let ((buf (get-buffer-create buffer-or-name))) 1220 (let ((buf (get-buffer-create buffer-or-name)))
1221 (set-buffer-major-mode buf) 1221 (set-buffer-major-mode buf)
1222 buf)))) 1222 buf))))
1223 (old-window (selected-window))
1224 (old-frame (selected-frame)) 1223 (old-frame (selected-frame))
1225 new-window new-frame) 1224 new-window new-frame)
1226 (set-buffer buffer) 1225 (set-buffer buffer)
1227 (setq new-window (display-buffer buffer other-window)) 1226 (setq new-window (display-buffer buffer other-window))
1228 (unless (eq new-window old-window) 1227 (select-window new-window norecord)
1229 ;; `display-buffer' has chosen another window, select it. 1228 (setq new-frame (window-frame new-window))
1230 (select-window new-window norecord) 1229 (unless (eq new-frame old-frame)
1231 (setq new-frame (window-frame new-window)) 1230 ;; `display-buffer' has chosen another frame, make sure it gets
1232 (unless (eq new-frame old-frame) 1231 ;; input focus and is risen.
1233 ;; `display-buffer' has chosen another frame, make sure it gets 1232 (select-frame-set-input-focus new-frame))
1234 ;; input focus and is risen.
1235 (select-frame-set-input-focus new-frame)))
1236 buffer)) 1233 buffer))
1237 1234
1238;; I think this should be the default; I think people will prefer it--rms. 1235;; I think this should be the default; I think people will prefer it--rms.