GNU bug report logs -
#33669
26.1; Buffer-menu-mode bad UX
Previous Next
Full log
Message #8 received at 33669 <at> debbugs.gnu.org (full text, mbox):
> From: Devon Sean McCullough <Emacs-Hacker2018 <at> jovi.net>
> Date: Sat, 8 Dec 2018 10:06:48 +0800
>
> When Buffer-menu-execute asks
>
> Buffer foo modified; kill anyway? (yes or no)
>
> and the reply is no,
> that line is removed anyway, deceiving the user
> by making the buffer menu incorrect.
>
> The user will promptly seek out such buffers — but they disappeared,
> giving the distressing wrong impression that they were killed anyway.
Thanks for reporting this. Does the patch below give good results?
diff --git a/lisp/buff-menu.el b/lisp/buff-menu.el
index bc1288a..95746b3 100644
--- a/lisp/buff-menu.el
+++ b/lisp/buff-menu.el
@@ -476,9 +476,10 @@ Buffer-menu-execute
(tabulated-list-set-col 2 " " t))
(error (warn "Error saving %s" buffer))))
(if delete
- (unless (eq buffer (current-buffer))
- (kill-buffer buffer)
- (tabulated-list-delete-entry))
+ (if (and (not (eq buffer (current-buffer)))
+ (kill-buffer buffer))
+ (tabulated-list-delete-entry)
+ (forward-line 1))
(forward-line 1)))))))))
(defun Buffer-menu-select ()
This bug report was last modified 6 years and 128 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.