diff options
author | Richard M. Stallman <[email protected]> | 1994-05-01 07:33:39 +0000 |
---|---|---|
committer | Richard M. Stallman <[email protected]> | 1994-05-01 07:33:39 +0000 |
commit | 3f9929bf5cc71a27e2817f8abb51d171f9b0ddae (patch) | |
tree | 0ba28b3a18febcbd4c4cc3f408794e451c40ebae /src | |
parent | cf770692be6cfe1e650b45f2bf82cab893923567 (diff) |
(Ftrack_mouse): Call prepare_menu_bars at the start.
(read_char): Don't call prepare_menu_bars if doing mouse tracking.
Diffstat (limited to 'src')
-rw-r--r-- | src/keyboard.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/keyboard.c b/src/keyboard.c index 1532141c45..4e26c8558b 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -1453,7 +1453,11 @@ read_char (commandflag, nmaps, maps, prev_event, used_mouse_menu) goto reread_first; } - if (commandflag >= 0 && !input_pending && !detect_input_pending ()) + /* Don't bother updating menu bars while doing mouse tracking. + We get events very rapidly then, and the menu bar won't be changing. + We do update the menu bar once on entry to Ftrack_mouse. */ + if (!do_mouse_tracking && + commandflag >= 0 && !input_pending && !detect_input_pending ()) prepare_menu_bars (); /* Save outer setjmp data, in case called recursively. */ @@ -1796,6 +1800,9 @@ Normally, mouse motion is ignored.") XSET (val, Lisp_Int, do_mouse_tracking); record_unwind_protect (tracking_off, val); + if (!input_pending && !detect_input_pending ()) + prepare_menu_bars (); + do_mouse_tracking = 1; val = Fprogn (args); |