Mercurial > emacs
changeset 56435:bc9ffd7cc15c
(list-buffers-noselect): Append the buffer's process status to its mode name.
author | Eli Zaretskii <eliz@gnu.org> |
---|---|
date | Fri, 16 Jul 2004 13:14:01 +0000 |
parents | a11286d6cf94 |
children | 416cdb28c139 |
files | lisp/buff-menu.el |
diffstat | 1 files changed, 10 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/buff-menu.el Fri Jul 16 10:42:43 2004 +0000 +++ b/lisp/buff-menu.el Fri Jul 16 13:14:01 2004 +0000 @@ -613,7 +613,7 @@ " " (Buffer-menu-make-sort-button "Mode" 4) mode-end (Buffer-menu-make-sort-button "File" 5) "\n")) - list desired-point name file) + list desired-point name mode file) (when Buffer-menu-use-header-line (let ((pos 0)) ;; Turn spaces in the header into stretch specs so they work @@ -638,8 +638,14 @@ (mapcar (lambda (buffer) (with-current-buffer buffer - (setq name (buffer-name) - file (buffer-file-name)) + (save-window-excursion + (setq name (buffer-name) + mode (progn + (set-window-buffer (selected-window) buffer) + (concat (format-mode-line mode-name) + (if mode-line-process + (format-mode-line mode-line-process)))) + file (buffer-file-name))) (cond ;; Don't mention internal buffers. ((and (string= (substring name 0 1) " ") (null file))) @@ -665,7 +671,7 @@ ?% ? ) ;; Identify modified buffers. (if (buffer-modified-p) ?* ? )) - name (buffer-size) mode-name file))))) + name (buffer-size) mode file))))) (buffer-list)))) (dolist (buffer (if Buffer-menu-sort-column