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

updated for version 7.4.601

Problem:    It is not possible to have feedkeys() insert characters.
Solution:   Add the 'i' flag.
This commit is contained in:
Bram Moolenaar
2015-01-27 15:19:24 +01:00
parent 0cd040b96a
commit 0a988df731
3 changed files with 13 additions and 5 deletions

View File

@@ -10500,6 +10500,7 @@ f_feedkeys(argvars, rettv)
typval_T *rettv UNUSED;
{
int remap = TRUE;
int insert = FALSE;
char_u *keys, *flags;
char_u nbuf[NUMBUFLEN];
int typed = FALSE;
@@ -10524,6 +10525,7 @@ f_feedkeys(argvars, rettv)
case 'n': remap = FALSE; break;
case 'm': remap = TRUE; break;
case 't': typed = TRUE; break;
case 'i': insert = TRUE; break;
}
}
}
@@ -10534,7 +10536,7 @@ f_feedkeys(argvars, rettv)
if (keys_esc != NULL)
{
ins_typebuf(keys_esc, (remap ? REMAP_YES : REMAP_NONE),
typebuf.tb_len, !typed, FALSE);
insert ? 0 : typebuf.tb_len, !typed, FALSE);
vim_free(keys_esc);
if (vgetc_busy)
typebuf_was_filled = TRUE;