patch 8.2.4099: Vim9: cannot use Vim9 syntax in mapping

Problem:    Vim9: cannot use Vim9 syntax in mapping.
Solution:   Add <ScriptCmd> to use the script context for a command.
This commit is contained in:
Bram Moolenaar
2022-01-15 18:26:04 +00:00
parent 069613c9e8
commit e32c3c462c
13 changed files with 113 additions and 22 deletions

View File

@ -276,6 +276,7 @@ enum key_extra
, KE_MOUSEMOVE_XY = 101 // KE_MOUSEMOVE with coordinates
, KE_CANCEL = 102 // return from vgetc()
, KE_COMMAND = 103 // <Cmd> special key
, KE_SCRIPT_COMMAND = 104 // <ScriptCmd> special key
};
/*
@ -480,6 +481,7 @@ enum key_extra
#define K_CURSORHOLD TERMCAP2KEY(KS_EXTRA, KE_CURSORHOLD)
#define K_COMMAND TERMCAP2KEY(KS_EXTRA, KE_COMMAND)
#define K_SCRIPT_COMMAND TERMCAP2KEY(KS_EXTRA, KE_SCRIPT_COMMAND)
// Bits for modifier mask
// 0x01 cannot be used, because the modifier must be 0x02 or higher