emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r100538: * window.el (pop-to-buffer):


From: Juri Linkov
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r100538: * window.el (pop-to-buffer): Remove the conditional that
Date: Mon, 07 Jun 2010 21:28:02 +0300
User-agent: Bazaar (2.0.3)

------------------------------------------------------------
revno: 100538
author: Martin Rudalics  <address@hidden>
committer: Juri Linkov <address@hidden>
branch nick: trunk
timestamp: Mon 2010-06-07 21:28:02 +0300
message:
  * 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
modified:
  lisp/ChangeLog
  lisp/window.el
  src/ChangeLog
  src/window.c
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2010-06-07 02:10:19 +0000
+++ b/lisp/ChangeLog    2010-06-07 18:28:02 +0000
@@ -1,3 +1,10 @@
+2010-06-07  Martin Rudalics  <address@hidden>
+
+       * 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
+
 2010-06-07  Stefan Monnier  <address@hidden>
 
        * emacs-lisp/smie.el (smie-indent-offset-after)

=== modified file 'lisp/window.el'
--- a/lisp/window.el    2010-04-16 01:41:58 +0000
+++ b/lisp/window.el    2010-06-07 18:28:02 +0000
@@ -1220,19 +1220,16 @@
                (let ((buf (get-buffer-create buffer-or-name)))
                  (set-buffer-major-mode buf)
                  buf))))
-       (old-window (selected-window))
        (old-frame (selected-frame))
        new-window new-frame)
     (set-buffer buffer)
     (setq new-window (display-buffer buffer other-window))
-    (unless (eq new-window old-window)
-      ;; `display-buffer' has chosen another window, select it.
-      (select-window new-window norecord)
-      (setq new-frame (window-frame new-window))
-      (unless (eq new-frame old-frame)
-       ;; `display-buffer' has chosen another frame, make sure it gets
-       ;; input focus and is risen.
-       (select-frame-set-input-focus new-frame)))
+    (select-window new-window norecord)
+    (setq new-frame (window-frame new-window))
+    (unless (eq new-frame old-frame)
+      ;; `display-buffer' has chosen another frame, make sure it gets
+      ;; input focus and is risen.
+      (select-frame-set-input-focus new-frame))
     buffer))
 
 ;; I think this should be the default; I think people will prefer it--rms.

=== modified file 'src/ChangeLog'
--- a/src/ChangeLog     2010-06-07 10:35:57 +0000
+++ b/src/ChangeLog     2010-06-07 18:28:02 +0000
@@ -1,3 +1,10 @@
+2010-06-07  Martin Rudalics  <address@hidden>
+
+       * 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
+
 2010-06-07  Juanma Barranquero  <address@hidden>
 
        * cmds.c (Fforward_char, Fbackward_char): Fix typos in docstrings.

=== modified file 'src/window.c'
--- a/src/window.c      2010-04-15 23:51:12 +0000
+++ b/src/window.c      2010-06-07 18:28:02 +0000
@@ -3611,6 +3611,7 @@
     {
       ++window_select_count;
       XSETFASTINT (w->use_time, window_select_count);
+      record_buffer (w->buffer);
     }
 
   if (EQ (window, selected_window))
@@ -3646,8 +3647,6 @@
 
   selected_window = window;
 
-  if (NILP (norecord))
-    record_buffer (w->buffer);
   Fset_buffer (w->buffer);
 
   XBUFFER (w->buffer)->last_selected_window = window;


reply via email to

[Prev in Thread] Current Thread [Next in Thread]