From: Glenn Morris Date: Fri, 16 Jan 2009 03:28:30 +0000 (+0000) Subject: (org-mouse-show-context-menu): Use mouse-menu-major-mode-map, if X-Git-Tag: emacs-pretest-23.0.90~420 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=0e47efc5038ea4677b2fdc790f80680841d13951;p=emacs.git (org-mouse-show-context-menu): Use mouse-menu-major-mode-map, if defined, rather than the obsolete mouse-major-mode-menu. --- diff --git a/lisp/org/ChangeLog b/lisp/org/ChangeLog index 4c9d42bb2ba..b2206cda0b1 100644 --- a/lisp/org/ChangeLog +++ b/lisp/org/ChangeLog @@ -1,3 +1,9 @@ +2009-01-16 Glenn Morris + + * org-mouse.el (org-mouse-show-context-menu): Use + mouse-menu-major-mode-map, if defined, rather than the obsolete + mouse-major-mode-menu. + 2008-12-23 Carsten Dominik * org-remember.el (org-remember-handler): Safer way to get a new diff --git a/lisp/org/org-mouse.el b/lisp/org/org-mouse.el index 279a81ad79e..1ae9f041a59 100644 --- a/lisp/org/org-mouse.el +++ b/lisp/org/org-mouse.el @@ -217,7 +217,10 @@ this function is called. Otherwise, the current major mode menu is used." (sit-for 0))) (if (functionp org-mouse-context-menu-function) (funcall org-mouse-context-menu-function event) - (mouse-major-mode-menu event prefix))) + (if (fboundp 'mouse-menu-major-mode-map) + (popup-menu (mouse-menu-major-mode-map) event prefix) + (with-no-warnings ; don't warn about fallback, obsolete since 23.1 + (mouse-major-mode-menu event prefix))))) (setq this-command 'mouse-save-then-kill) (mouse-save-then-kill event)))