# HG changeset patch # User Stefan Monnier # Date 1157958681 0 # Node ID 6e061fdbf037d561efdd34f249251c088ea1d1b6 # Parent 1804621e5f1e72e45848fefc6780d7079b06ca9b (mode-line-buffer-identification-keymap): Move initialization into declaration. diff -r 1804621e5f1e -r 6e061fdbf037 lisp/ChangeLog --- a/lisp/ChangeLog Mon Sep 11 02:39:16 2006 +0000 +++ b/lisp/ChangeLog Mon Sep 11 07:11:21 2006 +0000 @@ -1,3 +1,8 @@ +2006-09-11 Stefan Monnier + + * bindings.el (mode-line-buffer-identification-keymap): + Move initialization into declaration. + 2006-09-10 Kim F. Storm * ido.el (ido-edit-input, ido-complete, ido-take-first-match) @@ -30,8 +35,8 @@ 2006-09-09 Richard Stallman - * textmodes/conf-mode.el (conf-space-mode): Use - hack-local-variables-hook instead of calling hack-local-variables. + * textmodes/conf-mode.el (conf-space-mode): + Use hack-local-variables-hook instead of calling hack-local-variables. (conf-space-keywords-override): New variable. (conf-space-mode-internal): New subroutine. Reinit Font Lock mode. (conf-space-mode): Always make conf-space-keywords and diff -r 1804621e5f1e -r 6e061fdbf037 lisp/bindings.el --- a/lisp/bindings.el Mon Sep 11 02:39:16 2006 +0000 +++ b/lisp/bindings.el Mon Sep 11 07:11:21 2006 +0000 @@ -337,24 +337,22 @@ (put 'mode-line-position 'standard-value (list `(quote ,standard-mode-line-position)))) -(defvar mode-line-buffer-identification-keymap nil "\ +(defvar mode-line-buffer-identification-keymap + ;; Add menu of buffer operations to the buffer identification part + ;; of the mode line.or header line. + (let ((map (make-sparse-keymap))) + ;; Bind down- events so that the global keymap won't ``shine + ;; through''. + (define-key map [mode-line mouse-1] 'mode-line-previous-buffer) + (define-key map [header-line down-mouse-1] 'ignore) + (define-key map [header-line mouse-1] 'mode-line-previous-buffer) + (define-key map [header-line down-mouse-3] 'ignore) + (define-key map [mode-line mouse-3] 'mode-line-next-buffer) + (define-key map [header-line down-mouse-3] 'ignore) + (define-key map [header-line mouse-3] 'mode-line-next-buffer) + map) "\ Keymap for what is displayed by `mode-line-buffer-identification'.") -;; Add menu of buffer operations to the buffer identification part -;; of the mode line.or header line. -; -(let ((map (make-sparse-keymap))) - ;; Bind down- events so that the global keymap won't ``shine - ;; through''. - (define-key map [mode-line mouse-1] 'mode-line-previous-buffer) - (define-key map [header-line down-mouse-1] 'ignore) - (define-key map [header-line mouse-1] 'mode-line-previous-buffer) - (define-key map [header-line down-mouse-3] 'ignore) - (define-key map [mode-line mouse-3] 'mode-line-next-buffer) - (define-key map [header-line down-mouse-3] 'ignore) - (define-key map [header-line mouse-3] 'mode-line-next-buffer) - (setq mode-line-buffer-identification-keymap map)) - (defun propertized-buffer-identification (fmt) "Return a list suitable for `mode-line-buffer-identification'. FMT is a format specifier such as \"%12b\". This function adds