changeset 40648:a48a4d0806b4

(popup-menu): If the user refuses to select from a menu, don't try to invoke the menu.
author Richard M. Stallman <rms@gnu.org>
date Fri, 02 Nov 2001 07:14:16 +0000
parents e673a8c97e47
children 9ceb55408927
files lisp/mouse.el
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/mouse.el	Fri Nov 02 07:12:33 2001 +0000
+++ b/lisp/mouse.el	Fri Nov 02 07:14:16 2001 +0000
@@ -90,7 +90,9 @@
       (message "")
       ;; Maybe try again but with the submap.
       (setq map (if (keymapp cmd) cmd)))
-    (when (functionp cmd)
+    ;; If the user did not cancel by refusing to select,
+    ;; and if the result is a command, run it.
+    (when (and (null map) (commandp cmd))
       (setq prefix-arg prefix)
       ;; `setup-specified-language-environment', for instance,
       ;; expects this to be set from a menu keymap.