diff options
| author | Eli Zaretskii | 2020-12-12 17:32:55 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2020-12-12 17:32:55 +0200 |
| commit | a83d8c9bbe5fbcdeccebfc54d72e1019a951fe52 (patch) | |
| tree | 4fa174ea15ccf44f7a8cca72ffb1898a3a16b030 | |
| parent | 734f37136558f9cc4ae0d2d3507125d7e65c9986 (diff) | |
| download | emacs-a83d8c9bbe5fbcdeccebfc54d72e1019a951fe52.tar.gz emacs-a83d8c9bbe5fbcdeccebfc54d72e1019a951fe52.zip | |
Followup to recent changes in keyboard.c
* src/keyboard.c (prev_kbd_event): Now defined only if HAVE_X11.
* lisp/subr.el (while-no-input-ignore-events): Remove
'buffer-switch': no longer used or defined. (Bug#5803)
| -rw-r--r-- | lisp/subr.el | 2 | ||||
| -rw-r--r-- | src/keyboard.c | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/lisp/subr.el b/lisp/subr.el index c28807f694b..ed235ee1f72 100644 --- a/lisp/subr.el +++ b/lisp/subr.el | |||
| @@ -3964,7 +3964,7 @@ is allowed once again. (Immediately, if `inhibit-quit' is nil.)" | |||
| 3964 | ;; Don't throw `throw-on-input' on those events by default. | 3964 | ;; Don't throw `throw-on-input' on those events by default. |
| 3965 | (setq while-no-input-ignore-events | 3965 | (setq while-no-input-ignore-events |
| 3966 | '(focus-in focus-out help-echo iconify-frame | 3966 | '(focus-in focus-out help-echo iconify-frame |
| 3967 | make-frame-visible selection-request buffer-switch)) | 3967 | make-frame-visible selection-request)) |
| 3968 | 3968 | ||
| 3969 | (defmacro while-no-input (&rest body) | 3969 | (defmacro while-no-input (&rest body) |
| 3970 | "Execute BODY only as long as there's no pending input. | 3970 | "Execute BODY only as long as there's no pending input. |
diff --git a/src/keyboard.c b/src/keyboard.c index 560d92c99f3..dbca5be91e4 100644 --- a/src/keyboard.c +++ b/src/keyboard.c | |||
| @@ -384,11 +384,13 @@ next_kbd_event (union buffered_input_event *ptr) | |||
| 384 | return ptr == kbd_buffer + KBD_BUFFER_SIZE - 1 ? kbd_buffer : ptr + 1; | 384 | return ptr == kbd_buffer + KBD_BUFFER_SIZE - 1 ? kbd_buffer : ptr + 1; |
| 385 | } | 385 | } |
| 386 | 386 | ||
| 387 | #ifdef HAVE_X11 | ||
| 387 | static union buffered_input_event * | 388 | static union buffered_input_event * |
| 388 | prev_kbd_event (union buffered_input_event *ptr) | 389 | prev_kbd_event (union buffered_input_event *ptr) |
| 389 | { | 390 | { |
| 390 | return ptr == kbd_buffer ? kbd_buffer + KBD_BUFFER_SIZE - 1 : ptr - 1; | 391 | return ptr == kbd_buffer ? kbd_buffer + KBD_BUFFER_SIZE - 1 : ptr - 1; |
| 391 | } | 392 | } |
| 393 | #endif | ||
| 392 | 394 | ||
| 393 | /* Like EVENT_START, but assume EVENT is an event. | 395 | /* Like EVENT_START, but assume EVENT is an event. |
| 394 | This pacifies gcc -Wnull-dereference, which might otherwise | 396 | This pacifies gcc -Wnull-dereference, which might otherwise |