Mercurial > emacs
comparison lisp/mouse.el @ 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 | 00827567d7bd |
children | 0701d564260d |
comparison
equal
deleted
inserted
replaced
40647:e673a8c97e47 | 40648:a48a4d0806b4 |
---|---|
88 (lookup-key map (apply 'vector event)))) | 88 (lookup-key map (apply 'vector event)))) |
89 ;; Clear out echoing, which perhaps shows a prefix arg. | 89 ;; Clear out echoing, which perhaps shows a prefix arg. |
90 (message "") | 90 (message "") |
91 ;; Maybe try again but with the submap. | 91 ;; Maybe try again but with the submap. |
92 (setq map (if (keymapp cmd) cmd))) | 92 (setq map (if (keymapp cmd) cmd))) |
93 (when (functionp cmd) | 93 ;; If the user did not cancel by refusing to select, |
94 ;; and if the result is a command, run it. | |
95 (when (and (null map) (commandp cmd)) | |
94 (setq prefix-arg prefix) | 96 (setq prefix-arg prefix) |
95 ;; `setup-specified-language-environment', for instance, | 97 ;; `setup-specified-language-environment', for instance, |
96 ;; expects this to be set from a menu keymap. | 98 ;; expects this to be set from a menu keymap. |
97 (setq last-command-event (car (last event))) | 99 (setq last-command-event (car (last event))) |
98 ;; mouse-major-mode-menu was using `command-execute' instead. | 100 ;; mouse-major-mode-menu was using `command-execute' instead. |