From: Chong Yidong Date: Sat, 9 Feb 2013 05:52:20 +0000 (+0800) Subject: Bind view-echo-area-messages in minibuffer-inactive-mode-map. X-Git-Tag: emacs-24.3.90~173^2~7^2~118 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=123ecb68a0ba76a4f6b65c2a551e155022be2052;p=emacs.git Bind view-echo-area-messages in minibuffer-inactive-mode-map. * help.el (view-echo-area-messages): Use display-buffer. * minibuffer.el (minibuffer-inactive-mode-map): Bind mouse-1 to view-echo-area-messages. Fixes: debbugs:13340 --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6e1fe6d20ce..d0eba1bcb4c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,10 @@ 2013-02-09 Chong Yidong + * minibuffer.el (minibuffer-inactive-mode-map): Bind mouse-1 to + view-echo-area-messages (Bug#13340). + + * help.el (view-echo-area-messages): Use display-buffer. + * dired-x.el (dired-do-run-mail): Prompt for confirmation (Bug#13561). diff --git a/lisp/help.el b/lisp/help.el index 4219dd86986..25bc9c4b7c6 100644 --- a/lisp/help.el +++ b/lisp/help.el @@ -412,7 +412,9 @@ With argument, display info only for the selected version." The number of messages retained in that buffer is specified by the variable `message-log-max'." (interactive) - (switch-to-buffer (get-buffer-create "*Messages*"))) + (with-current-buffer (get-buffer-create "*Messages*") + (goto-char (point-max)) + (display-buffer (current-buffer)))) (defun view-order-manuals () "Display the Emacs ORDERS file." diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 0d2815e535e..e18f4c9c77f 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -2045,10 +2045,7 @@ with `minibuffer-local-must-match-map'.") (define-key map "i" 'info) (define-key map "m" 'mail) (define-key map "n" 'make-frame) - (define-key map [mouse-1] (lambda () (interactive) - (with-current-buffer "*Messages*" - (goto-char (point-max)) - (display-buffer (current-buffer))))) + (define-key map [mouse-1] 'view-echo-area-messages) ;; So the global down-mouse-1 binding doesn't clutter the execution of the ;; above mouse-1 binding. (define-key map [down-mouse-1] #'ignore)