diff options
author | zeertzjq <zeertzjq@outlook.com> | 2021-11-04 21:43:05 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-04 07:43:05 -0600 |
commit | 5ce35abae6427dac7ac2b147bae8f16adcd8ddff (patch) | |
tree | 12c3c386862a59bf04404647d563156963751164 /src | |
parent | fd347840ba95b2709b90d5a3131f59b72fbad7fb (diff) | |
download | rneovim-5ce35abae6427dac7ac2b147bae8f16adcd8ddff.tar.gz rneovim-5ce35abae6427dac7ac2b147bae8f16adcd8ddff.tar.bz2 rneovim-5ce35abae6427dac7ac2b147bae8f16adcd8ddff.zip |
fix(input): never reinterpret unmapped ALT- chrods in Terminal mode (#16222)
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/getchar.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/nvim/getchar.c b/src/nvim/getchar.c index a374406716..a04914efd5 100644 --- a/src/nvim/getchar.c +++ b/src/nvim/getchar.c @@ -1579,7 +1579,8 @@ int vgetc(void) // If mappings are enabled (i.e., not Ctrl-v) and the user directly typed // something with a meta- or alt- modifier that was not mapped, interpret // <M-x> as <Esc>x rather than as an unbound meta keypress. #8213 - if (!no_mapping && KeyTyped + // In Terminal mode, however, this is not desirable. #16220 + if (!no_mapping && KeyTyped && !(State & TERM_FOCUS) && (mod_mask == MOD_MASK_ALT || mod_mask == MOD_MASK_META)) { mod_mask = 0; ins_char_typebuf(c); |