# HG changeset patch # User Eli Zaretskii # Date 1148670705 0 # Node ID b4e6091c234653f0a5067d6f3054eec57f088a0a # Parent ea71fd2eadcb7b676f49ff39f12945f705d79368 (list-buffers-noselect): For Info buffers, use Info-current-file as the file name. diff -r ea71fd2eadcb -r b4e6091c2346 lisp/buff-menu.el --- a/lisp/buff-menu.el Fri May 26 18:45:35 2006 +0000 +++ b/lisp/buff-menu.el Fri May 26 19:11:45 2006 +0000 @@ -116,6 +116,8 @@ file buffers. It affects both manual reverting and reverting by Auto Revert Mode.") +(defvar Info-current-file) ;; from info.el + (make-variable-buffer-local 'Buffer-menu-files-only) (if Buffer-menu-mode-map @@ -767,10 +769,24 @@ ?\s))) (unless file ;; No visited file. Check local value of - ;; list-buffers-directory. - (when (and (boundp 'list-buffers-directory) - list-buffers-directory) - (setq file list-buffers-directory))) + ;; list-buffers-directory and, for Info buffers, + ;; Info-current-file. + (cond ((and (boundp 'list-buffers-directory) + list-buffers-directory) + (setq file list-buffers-directory)) + ((eq major-mode 'Info-mode) + (setq file Info-current-file) + (cond + ((eq file t) + (setq file "*Info Directory*")) + ((eq file 'apropos) + (setq file "*Info Apropos*")) + ((eq file 'history) + (setq file "*Info History*")) + ((eq file 'toc) + (setq file "*Info TOC*")) + ((not (stringp file)) ;; avoid errors + (setq file nil)))))) (push (list buffer bits name (buffer-size) mode file) list)))))) ;; Preserve the original buffer-list ordering, just in case.