diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2013-03-19 08:47:10 -0400 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2013-03-19 08:47:10 -0400 |
commit | 0e6008c58ee197de5708e6c26e4994da89945c4f (patch) | |
tree | 05676efbcd3eb4e2fa8e948bf8e2ce2b353a24ff /lisp/mouse.el | |
parent | 095d384da66c2b227803a0540d9bde9df52a97e1 (diff) | |
download | emacs-0e6008c58ee197de5708e6c26e4994da89945c4f.tar.gz |
* lisp/mouse.el (mouse--down-1-maybe-follows-link): Fix follow-link
remapping in mode-line.
(mouse-on-link-p): Also check [mode-line follow-link] bindings.
Diffstat (limited to 'lisp/mouse.el')
-rw-r--r-- | lisp/mouse.el | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/lisp/mouse.el b/lisp/mouse.el index ea6b1b04de0..333a1cef703 100644 --- a/lisp/mouse.el +++ b/lisp/mouse.el @@ -128,7 +128,11 @@ Expects to be bound to `down-mouse-1' in `key-translation-map'." (put newup 'event-kind (get (car event) 'event-kind)) (put newdown 'event-kind (get (car this-event) 'event-kind)) (push (cons newup (cdr event)) unread-command-events) - (vector (cons newdown (cdr this-event)))) + ;; Modify the event in place, so read-key-sequence doesn't + ;; generate a second fake prefix key (see fake_prefixed_keys in + ;; src/keyboard.c). + (setcar this-event newdown) + (vector this-event)) (push event unread-command-events) nil)))))) @@ -760,6 +764,9 @@ at the same position." mouse-1-click-in-non-selected-windows (eq (selected-window) (posn-window pos))) (or (mouse-posn-property pos 'follow-link) + (let ((area (posn-area pos))) + (when area + (key-binding (vector area 'follow-link) nil t pos))) (key-binding [follow-link] nil t pos))))) (cond ((eq action 'mouse-face) |