0
0
mirror of https://github.com/vim/vim.git synced 2025-09-27 04:14:06 -04:00

patch 8.2.1988: still in Insert mode when opening terminal popup

Problem:    Still in Insert mode when opening terminal popup with a <Cmd>
            mapping in Insert mode.
Solution:   Exit Insert mode. (closes #7295)
This commit is contained in:
Bram Moolenaar
2020-11-14 21:34:59 +01:00
parent 6453cc8078
commit e41decc892
3 changed files with 25 additions and 0 deletions

View File

@@ -1033,6 +1033,11 @@ doESCkey:
case K_COMMAND: // <Cmd>command<CR>
do_cmdline(NULL, getcmdkeycmd, NULL, 0);
#ifdef FEAT_TERMINAL
if (term_use_loop())
// Started a terminal that gets the input, exit Insert mode.
goto doESCkey;
#endif
break;
case K_CURSORHOLD: // Didn't type something for a while.