fix(events): make CursorHold behave as documented

This commit is contained in:
zeertzjq
2022-09-14 19:49:55 +08:00
parent 3c3f3e7353
commit 644a3f48b1
4 changed files with 72 additions and 13 deletions

View File

@@ -65,7 +65,7 @@ getkey:
// Call `os_inchar` directly to block for events or user input without
// consuming anything from `input_buffer`(os/input.c) or calling the
// mapping engine.
(void)os_inchar(NULL, 0, -1, 0, main_loop.events);
(void)os_inchar(NULL, 0, -1, typebuf.tb_change_cnt, main_loop.events);
// If an event was put into the queue, we send K_EVENT directly.
if (!multiqueue_empty(main_loop.events)) {
key = K_EVENT;