patch 9.1.0563: Cannot process any Key event
Problem: Cannot process any Key event
Solution: Add the KeyInputPre autocmd
(Shougo Matsushita)
closes: #15182
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Co-authored-by: K.Takata <kentkt@csc.jp>
Signed-off-by: Shougo Matsushita <Shougo.Matsu@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
e7b98ab96e
commit
8367884909
@ -155,6 +155,7 @@ static keyvalue_T event_tab[] = {
|
||||
KEYVALUE_ENTRY(EVENT_INSERTENTER, "InsertEnter"),
|
||||
KEYVALUE_ENTRY(EVENT_INSERTLEAVE, "InsertLeave"),
|
||||
KEYVALUE_ENTRY(EVENT_INSERTLEAVEPRE, "InsertLeavePre"),
|
||||
KEYVALUE_ENTRY(EVENT_KEYINPUTPRE, "KeyInputPre"),
|
||||
KEYVALUE_ENTRY(EVENT_MENUPOPUP, "MenuPopup"),
|
||||
KEYVALUE_ENTRY(EVENT_MODECHANGED, "ModeChanged"),
|
||||
KEYVALUE_ENTRY(EVENT_OPTIONSET, "OptionSet"),
|
||||
@ -2021,6 +2022,15 @@ has_insertcharpre(void)
|
||||
return (first_autopat[(int)EVENT_INSERTCHARPRE] != NULL);
|
||||
}
|
||||
|
||||
/*
|
||||
* Return TRUE when there is an KeyInputPre autocommand defined.
|
||||
*/
|
||||
int
|
||||
has_keyinputpre(void)
|
||||
{
|
||||
return (first_autopat[(int)EVENT_KEYINPUTPRE] != NULL);
|
||||
}
|
||||
|
||||
/*
|
||||
* Return TRUE when there is an CmdUndefined autocommand defined.
|
||||
*/
|
||||
@ -2256,6 +2266,7 @@ apply_autocmds_group(
|
||||
|| event == EVENT_CMDWINLEAVE
|
||||
|| event == EVENT_CMDUNDEFINED
|
||||
|| event == EVENT_FUNCUNDEFINED
|
||||
|| event == EVENT_KEYINPUTPRE
|
||||
|| event == EVENT_REMOTEREPLY
|
||||
|| event == EVENT_SPELLFILEMISSING
|
||||
|| event == EVENT_QUICKFIXCMDPRE
|
||||
|
||||
Reference in New Issue
Block a user