From a8fec63e5627f5f77d840f7a4ae276854a43549b Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Wed, 6 Jul 2005 18:54:52 +0000 Subject: [PATCH] Re-add global mouse-2 event. * lisp/muse-mode.el (muse-mode-map): Re-add the global binding for mouse-2, since Yann found a way around the problem I was facing. (muse-follow-name-at-mouse): Call the event that would normally be used here if we don't have a link at point. git-archimport-id: mwolson@gnu.org--2005/muse--main--1.0--patch-93 --- ChangeLog | 17 +++++++++++++++++ lisp/muse-mode.el | 16 +++++++++++++--- 2 files changed, 30 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 4b68efa..baec015 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,23 @@ # arch-tag: automatic-ChangeLog--mwolson@gnu.org--2005/muse--main--1.0 # +2005-07-06 18:54:52 GMT Michael Olson patch-93 + + Summary: + Re-add global mouse-2 event. + Revision: + muse--main--1.0--patch-93 + + * lisp/muse-mode.el (muse-mode-map): Re-add the global binding for + mouse-2, since Yann found a way around the problem I was facing. + (muse-follow-name-at-mouse): Call the event that would normally be used + here if we don't have a link at point. + + + modified files: + ChangeLog lisp/muse-mode.el + + 2005-07-06 07:19:41 GMT Michael Olson patch-92 Summary: diff --git a/lisp/muse-mode.el b/lisp/muse-mode.el index 53040ad..26caef9 100644 --- a/lisp/muse-mode.el +++ b/lisp/muse-mode.el @@ -105,9 +105,16 @@ so only enable this if you don't use either of these." (define-key map [tab] 'muse-next-reference) (define-key map [(control ?i)] 'muse-next-reference) - (unless (featurep 'xemacs) + (if (featurep 'xemacs) + (progn + (define-key map [(button2)] 'muse-follow-name-at-mouse) + (define-key map [(shift button2)] + 'muse-follow-name-at-mouse-other-window)) (define-key map [(shift control ?m)] - 'muse-follow-name-at-point-other-window)) + 'muse-follow-name-at-point-other-window) + (define-key map [mouse-2] 'muse-follow-name-at-mouse) + (define-key map [(shift mouse-2)] + 'muse-follow-name-at-mouse-other-window)) (if (featurep 'xemacs) (define-key map [(shift tab)] 'muse-previous-reference) @@ -347,7 +354,10 @@ in `muse-project-alist'." (goto-char (posn-point (event-start event))))) (let ((link (muse-link-at-point))) (if link - (muse-visit-link link other-window))))) + (muse-visit-link link other-window) + ;; Fall back to normal binding for this event + (call-interactively + (lookup-key (current-global-map) (this-command-keys))))))) (defun muse-follow-name-at-mouse-other-window (event) "Visit the link at point" -- 2.11.4.GIT