X-Git-Url: http://git.chise.org/gitweb/?p=chise%2Fxemacs-chise.git.1;a=blobdiff_plain;f=lisp%2Fbuffer.el;h=057583b8a17673b986a7a7d790bc1b1504eb7b8b;hp=c8292845f71166004069b6e0ab64e77763a3cb44;hb=52b3dd1157cecb0f190b11a0874fcb0a5df5e0e2;hpb=f3ec20f455f3f1212d2c5ee4cadc984330da9c38 diff --git a/lisp/buffer.el b/lisp/buffer.el index c829284..057583b 100644 --- a/lisp/buffer.el +++ b/lisp/buffer.el @@ -60,11 +60,7 @@ the window-buffer correspondences." (set-buffer-major-mode buf)))) (push-window-configuration) (set-buffer buf) - (or norecord (record-buffer buf)) - (set-window-buffer (if (eq (selected-window) (minibuffer-window)) - (next-window (minibuffer-window)) - (selected-window)) - buf) + (set-window-buffer (last-nonminibuf-window) buf norecord) buf)) (defun pop-to-buffer (bufname &optional not-this-window-p on-frame) @@ -75,7 +71,12 @@ If optional second arg NOT-THIS-WINDOW-P is non-nil, insist on finding another window even if BUFNAME is already visible in the selected window. If optional third arg is non-nil, it is the frame to pop to this buffer on. -If `focus-follows-mouse' is non-nil, keyboard focus is left unchanged." +If `focus-follows-mouse' is non-nil, keyboard focus is left unchanged. + +Buffers with names that are members of the `same-window-buffer-names' +list, or that match an element of the `same-window-regexps' list are +treated specially by this function--they are always selected in the +same window rather than in a different one." ;; #ifdef I18N3 ;; #### Doc string should indicate that the buffer name will get ;; translated.