diff options
| author | Sam Steingold | 2001-11-19 16:32:37 +0000 |
|---|---|---|
| committer | Sam Steingold | 2001-11-19 16:32:37 +0000 |
| commit | 545f73103e4f0460ada22f98d0c11cc830a15490 (patch) | |
| tree | a078665d1fb40363412bb87ff240e6179c4323e0 | |
| parent | aff37336ea0e27a5cbc61b42b63d28a9d74b1498 (diff) | |
| download | emacs-545f73103e4f0460ada22f98d0c11cc830a15490.tar.gz emacs-545f73103e4f0460ada22f98d0c11cc830a15490.zip | |
(last-buffer, unbury-buffer): New functions.
(mode-line-unbury-buffer): Use `unbury-buffer'.
| -rw-r--r-- | lisp/ChangeLog | 13 | ||||
| -rw-r--r-- | lisp/bindings.el | 21 |
2 files changed, 24 insertions, 10 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 32a3c1eec6a..9e1b8624a80 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2001-11-19 Sam Steingold <sds@gnu.org> | ||
| 2 | |||
| 3 | * bindings.el (last-buffer, unbury-buffer): New function. | ||
| 4 | (mode-line-unbury-buffer): Use `unbury-buffer'. | ||
| 5 | |||
| 1 | 2001-11-18 Stephen Eglen <stephen@gnu.org> | 6 | 2001-11-18 Stephen Eglen <stephen@gnu.org> |
| 2 | 7 | ||
| 3 | * iswitchb.el (iswitchb-cannot-complete-hook): New variable to | 8 | * iswitchb.el (iswitchb-cannot-complete-hook): New variable to |
| @@ -17,12 +22,12 @@ | |||
| 17 | (Math-num-integerp, Math-bignum-test, Math-equal-int) | 22 | (Math-num-integerp, Math-bignum-test, Math-equal-int) |
| 18 | (Math-natnum-lessp, math-format-radix-digit): Change to `defsubst'. | 23 | (Math-natnum-lessp, math-format-radix-digit): Change to `defsubst'. |
| 19 | (calc-record-compilation-date-macro): Deleted. Callers updated. | 24 | (calc-record-compilation-date-macro): Deleted. Callers updated. |
| 20 | (math-format-radix-digit): Move to calc-bin.el. | 25 | (math-format-radix-digit): Move to calc-bin.el. |
| 21 | 26 | ||
| 22 | * calc/calc.el (calc-record-compilation-date): Remove. | 27 | * calc/calc.el (calc-record-compilation-date): Remove. |
| 23 | (calc-bug-address): Update. | 28 | (calc-bug-address): Update. |
| 24 | (calc-settings-file): Use `user-init-file'. | 29 | (calc-settings-file): Use `user-init-file'. |
| 25 | 30 | ||
| 26 | * calc/calc-mode.el (calc-settings-file-name, calc-save-modes): | 31 | * calc/calc-mode.el (calc-settings-file-name, calc-save-modes): |
| 27 | Handle null `calc-settings-file'. | 32 | Handle null `calc-settings-file'. |
| 28 | 33 | ||
| @@ -38,7 +43,7 @@ | |||
| 38 | (calcFunc-floor): Ditto. | 43 | (calcFunc-floor): Ditto. |
| 39 | 44 | ||
| 40 | * calc-units.el (calcFunc-usimplify): Ditto. | 45 | * calc-units.el (calcFunc-usimplify): Ditto. |
| 41 | 46 | ||
| 42 | * calc-aent.el, calc-ext.el, calc-incom.el, calc-misc.el | 47 | * calc-aent.el, calc-ext.el, calc-incom.el, calc-misc.el |
| 43 | * calc-sel.el, calc-vec.el, calc-alg.el, calc-fin.el | 48 | * calc-sel.el, calc-vec.el, calc-alg.el, calc-fin.el |
| 44 | * calc-keypd.el, calc-mode.el, calc-stat.el, calc-yank.el | 49 | * calc-keypd.el, calc-mode.el, calc-stat.el, calc-yank.el |
| @@ -53,7 +58,7 @@ | |||
| 53 | and move them before their first use. Use `when', `unless'. | 58 | and move them before their first use. Use `when', `unless'. |
| 54 | Remove trailing periods from error forms. Add description and | 59 | Remove trailing periods from error forms. Add description and |
| 55 | headers suggested by Emacs Lisp coding conventions. | 60 | headers suggested by Emacs Lisp coding conventions. |
| 56 | 61 | ||
| 57 | 2001-11-19 Stefan Monnier <monnier@cs.yale.edu> | 62 | 2001-11-19 Stefan Monnier <monnier@cs.yale.edu> |
| 58 | 63 | ||
| 59 | * newcomment.el (comment-indent): | 64 | * newcomment.el (comment-indent): |
diff --git a/lisp/bindings.el b/lisp/bindings.el index 3f64044554b..8731e6f5817 100644 --- a/lisp/bindings.el +++ b/lisp/bindings.el | |||
| @@ -258,7 +258,7 @@ Normally nil in most modes, since there is no process to display.") | |||
| 258 | 'mouse-2 #'mode-line-widen)) | 258 | 'mouse-2 #'mode-line-widen)) |
| 259 | (propertize ")%]--" 'help-echo help-echo))) | 259 | (propertize ")%]--" 'help-echo help-echo))) |
| 260 | 260 | ||
| 261 | (setq-default mode-line-position | 261 | (setq-default mode-line-position |
| 262 | `((line-number-mode (,(propertize "L%l" 'help-echo help-echo) ,dashes)) | 262 | `((line-number-mode (,(propertize "L%l" 'help-echo help-echo) ,dashes)) |
| 263 | (column-number-mode (,(propertize "C%c" 'help-echo help-echo) ,dashes)) | 263 | (column-number-mode (,(propertize "C%c" 'help-echo help-echo) ,dashes)) |
| 264 | (-3 . ,(propertize "%p" 'help-echo help-echo))))) | 264 | (-3 . ,(propertize "%p" 'help-echo help-echo))))) |
| @@ -272,15 +272,24 @@ Keymap for what is displayed by `mode-line-mode-name'.") | |||
| 272 | (defvar mode-line-mode-menu-keymap nil "\ | 272 | (defvar mode-line-mode-menu-keymap nil "\ |
| 273 | Keymap for mode operations menu in the mode line.") | 273 | Keymap for mode operations menu in the mode line.") |
| 274 | 274 | ||
| 275 | (defun last-buffer () " | ||
| 276 | Return the last non-hidden buffer in the buffer list." | ||
| 277 | (let ((list (reverse (buffer-list)))) | ||
| 278 | (while (eq (aref (buffer-name (car list)) 0) ? ) | ||
| 279 | (setq list (cdr list))) | ||
| 280 | (car list))) | ||
| 281 | |||
| 282 | (defun unbury-buffer () " | ||
| 283 | Switch to the `last-buffer'." | ||
| 284 | (interactive) | ||
| 285 | (switch-to-buffer (last-buffer))) | ||
| 286 | |||
| 275 | (defun mode-line-unbury-buffer (event) "\ | 287 | (defun mode-line-unbury-buffer (event) "\ |
| 276 | Switch to the last buffer in the buffer list that is not hidden." | 288 | Call `unbury-buffer' in this window." |
| 277 | (interactive "e") | 289 | (interactive "e") |
| 278 | (save-selected-window | 290 | (save-selected-window |
| 279 | (select-window (posn-window (event-start event))) | 291 | (select-window (posn-window (event-start event))) |
| 280 | (let ((list (reverse (buffer-list)))) | 292 | (unbury-buffer))) |
| 281 | (while (eq (aref (buffer-name (car list)) 0) ? ) | ||
| 282 | (setq list (cdr list))) | ||
| 283 | (switch-to-buffer (car list))))) | ||
| 284 | 293 | ||
| 285 | (defun mode-line-bury-buffer (event) "\ | 294 | (defun mode-line-bury-buffer (event) "\ |
| 286 | Like bury-buffer, but temporarily select EVENT's window." | 295 | Like bury-buffer, but temporarily select EVENT's window." |