mirror of
https://github.com/neovim/neovim.git
synced 2025-09-27 21:48:35 +00:00
lua: add vim.register_keystroke_callback (#12536)
* feat: Add vim.register_keystroke_callback * fixup: Forgot to remove mention of old option * fixup: Answer jamessan comments * fixup: Answer norcalli comments * fixup: portability * Update runtime/doc/lua.txt Co-authored-by: Ashkan Kiani <ashkan.k.kiani@gmail.com>
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
#include "nvim/ex_docmd.h"
|
||||
#include "nvim/ex_getln.h"
|
||||
#include "nvim/func_attr.h"
|
||||
#include "nvim/lua/executor.h"
|
||||
#include "nvim/main.h"
|
||||
#include "nvim/mbyte.h"
|
||||
#include "nvim/memline.h"
|
||||
@@ -1535,6 +1536,9 @@ int vgetc(void)
|
||||
*/
|
||||
may_garbage_collect = false;
|
||||
|
||||
// Exec lua callbacks for on_keystroke
|
||||
nlua_execute_log_keystroke(c);
|
||||
|
||||
return c;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user