From: Richard M. Stallman Date: Wed, 21 Apr 2004 19:14:49 +0000 (+0000) Subject: (easy-menu-add): Do call x-popup-menu, but only if it's defined. X-Git-Tag: ttn-vms-21-2-B4~6682 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=67d170f2d238536b6180b922d797e9c1cf6ed198;p=emacs.git (easy-menu-add): Do call x-popup-menu, but only if it's defined. --- diff --git a/lisp/emacs-lisp/easymenu.el b/lisp/emacs-lisp/easymenu.el index 88f7657b6bf..dbd7194f50a 100644 --- a/lisp/emacs-lisp/easymenu.el +++ b/lisp/emacs-lisp/easymenu.el @@ -478,8 +478,8 @@ Do it only if `easy-menu-precalculate-equivalent-keybindings' is on." (when easy-menu-precalculate-equivalent-keybindings (if (and (symbolp menu) (not (keymapp menu)) (boundp menu)) (setq menu (symbol-value menu))) - ;; x-popup-menu does not exist on tty-only Emacs. - ;; (if (keymapp menu) (x-popup-menu nil menu)) + (and (keymapp menu) (fboundp 'x-popup-menu) + (x-popup-menu nil menu)) )) (defun add-submenu (menu-path submenu &optional before in-menu)