# HG changeset patch # User David Kastrup # Date 1159884226 0 # Node ID b4697c34c8fdae3b9cb6ffccb7dabb0afff97334 # Parent 5f8a28d018b2e55dfeaefcc41b7895d1e743ddc8 * help.el (describe-mode): For clicks on mode-line, use "@" interactive argument to get the major mode of the click instead of the current buffer. * isearch.el (isearch-mouse-2): Use new semantics of `key-binding' in order to better redirect mouse-2 clicks. Also allow default bindings to apply. diff -r 5f8a28d018b2 -r b4697c34c8fd lisp/ChangeLog --- a/lisp/ChangeLog Tue Oct 03 13:47:26 2006 +0000 +++ b/lisp/ChangeLog Tue Oct 03 14:03:46 2006 +0000 @@ -1,3 +1,13 @@ +2006-10-03 David Kastrup + + * help.el (describe-mode): For clicks on mode-line, use "@" + interactive argument to get the major mode of the click instead of + the current buffer. + + * isearch.el (isearch-mouse-2): Use new semantics of `key-binding' + in order to better redirect mouse-2 clicks. Also allow default + bindings to apply. + 2006-10-03 Kim F. Storm * emacs-lisp/cl.el (pushnew-internal): Remove defvar. diff -r 5f8a28d018b2 -r b4697c34c8fd lisp/help.el --- a/lisp/help.el Tue Oct 03 13:47:26 2006 +0000 +++ b/lisp/help.el Tue Oct 03 14:03:46 2006 +0000 @@ -764,7 +764,7 @@ For this to work correctly for a minor mode, the mode's indicator variable \(listed in `minor-mode-alist') must also be a function whose documentation describes the minor mode." - (interactive) + (interactive "@") (unless buffer (setq buffer (current-buffer))) (help-setup-xref (list #'describe-mode buffer) (interactive-p)) diff -r 5f8a28d018b2 -r b4697c34c8fd lisp/isearch.el --- a/lisp/isearch.el Tue Oct 03 13:47:26 2006 +0000 +++ b/lisp/isearch.el Tue Oct 03 14:03:46 2006 +0000 @@ -1293,23 +1293,18 @@ (defun isearch-mouse-2 (click) "Handle mouse-2 in Isearch mode. For a click in the echo area, invoke `isearch-yank-x-selection'. -Otherwise invoke whatever mouse-2 is bound to outside of Isearch." +Otherwise invoke whatever the calling mouse-2 command sequence +is bound to outside of Isearch." (interactive "e") (let* ((w (posn-window (event-start click))) (overriding-terminal-local-map nil) - (key (vector (event-basic-type click))) - ;; FIXME: `key-binding' should accept an event as argument - ;; and do all the overlay/text-properties lookup etc... - (binding (with-current-buffer - (if (window-live-p w) (window-buffer w) (current-buffer)) - (key-binding key)))) + (binding (key-binding (this-command-keys-vector) t))) (if (and (window-minibuffer-p w) (not (minibuffer-window-active-p w))) ; in echo area (isearch-yank-x-selection) (when (functionp binding) (call-interactively binding))))) - (defun isearch-yank-internal (jumpform) "Pull the text from point to the point reached by JUMPFORM. JUMPFORM is a lambda expression that takes no arguments and returns a