bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#9761: proposed list-buffers change -- revert buffer if point is in *


From: Zachary Kanfer
Subject: bug#9761: proposed list-buffers change -- revert buffer if point is in *Buffer List* buffer
Date: Sat, 15 Oct 2011 00:22:43 -0400

The command list-buffers always puts point at the end of the buffer. This patch changes the list-buffers command to simply revert the buffer if point is inside the *Buffer List* buffer. Since point is kept at the same line, the user can more easily see what changes have occurred.
 -Zachary Kanfer


=== modified file 'lisp/buff-menu.el'
*** lisp/buff-menu.el    2011-09-18 20:43:20 +0000
--- lisp/buff-menu.el    2011-10-15 03:59:12 +0000
*************** Non-null optional arg FILES-ONLY means m
*** 652,658 ****
 
  For more information, see the function `buffer-menu'."
    (interactive "P")
!   (display-buffer (list-buffers-noselect files-only)))
 
  (defconst Buffer-menu-short-ellipsis
    ;; This file is preloaded, so we can't use char-displayable-p here
--- 652,661 ----
 
  For more information, see the function `buffer-menu'."
    (interactive "P")
!   (if (string= (buffer-name)
!                "*Buffer List*")
!       (revert-buffer)
!     (display-buffer (list-buffers-noselect files-only))))
 
  (defconst Buffer-menu-short-ellipsis
    ;; This file is preloaded, so we can't use char-displayable-p here


reply via email to

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