diff options
| author | Stefan Monnier | 2013-02-11 14:21:23 -0500 |
|---|---|---|
| committer | Stefan Monnier | 2013-02-11 14:21:23 -0500 |
| commit | 99d0d6dc23f0fd2ee6d64f0f18a33f2b791c642d (patch) | |
| tree | 2cd8a54c22c9354415306c76bd65dddde723532f /src/lread.c | |
| parent | f5e1b6804dc2307983e4c55d4d6530549ddccbb7 (diff) | |
| download | emacs-99d0d6dc23f0fd2ee6d64f0f18a33f2b791c642d.tar.gz emacs-99d0d6dc23f0fd2ee6d64f0f18a33f2b791c642d.zip | |
Clean up read_key_sequence a bit; reread active keymaps after first event.
* src/keyboard.c (read_char, read_char_x_menu_prompt)
(read_char_minibuf_menu_prompt):
Replace nmaps+maps with a single `map' arg.
(follow_key): Operate on a single map.
(active_maps): New function.
(test_undefined): Also return true for nil bindings.
(read_key_sequence): Use active_maps to replace the arrays of keymaps with
a single (composed) keymap. Remember `first_event' to choose the right
set of active keymaps. Recompute the set of keymaps after receiving
the first event. Remove GOBBLE_FIRST_EVENT.
(syms_of_keyboard): Remove inhibit_local_menu_bar_menus.
* src/keyboard.h (read_char): Update declaration.
* src/lread.c (read_filtered_event): Adjust call to read_char.
* lisp/cus-start.el (all): Remove inhibit-local-menu-bar-menus.
Diffstat (limited to 'src/lread.c')
| -rw-r--r-- | src/lread.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lread.c b/src/lread.c index c62c62a5e5a..e7af86aa664 100644 --- a/src/lread.c +++ b/src/lread.c | |||
| @@ -614,17 +614,17 @@ read_filtered_event (bool no_switch_frame, bool ascii_required, | |||
| 614 | end_time = add_emacs_time (current_emacs_time (), wait_time); | 614 | end_time = add_emacs_time (current_emacs_time (), wait_time); |
| 615 | } | 615 | } |
| 616 | 616 | ||
| 617 | /* Read until we get an acceptable event. */ | 617 | /* Read until we get an acceptable event. */ |
| 618 | retry: | 618 | retry: |
| 619 | do | 619 | do |
| 620 | val = read_char (0, 0, 0, (input_method ? Qnil : Qt), 0, | 620 | val = read_char (0, Qnil, (input_method ? Qnil : Qt), 0, |
| 621 | NUMBERP (seconds) ? &end_time : NULL); | 621 | NUMBERP (seconds) ? &end_time : NULL); |
| 622 | while (INTEGERP (val) && XINT (val) == -2); /* wrong_kboard_jmpbuf */ | 622 | while (INTEGERP (val) && XINT (val) == -2); /* wrong_kboard_jmpbuf */ |
| 623 | 623 | ||
| 624 | if (BUFFERP (val)) | 624 | if (BUFFERP (val)) |
| 625 | goto retry; | 625 | goto retry; |
| 626 | 626 | ||
| 627 | /* switch-frame events are put off until after the next ASCII | 627 | /* `switch-frame' events are put off until after the next ASCII |
| 628 | character. This is better than signaling an error just because | 628 | character. This is better than signaling an error just because |
| 629 | the last characters were typed to a separate minibuffer frame, | 629 | the last characters were typed to a separate minibuffer frame, |
| 630 | for example. Eventually, some code which can deal with | 630 | for example. Eventually, some code which can deal with |