mirror of
https://github.com/neovim/neovim.git
synced 2026-01-26 07:01:54 +10:00
vim-patch:8.1.2385: open cmdline window with feedkeys() #11516
Problem: Opening cmdline window with feedkeys() does not work. (Yegappan
Lakshmanan)
Solution: Recognize K_CMDWIN also when ex_normal_busy is set.
85db547598
This commit is contained in:
committed by
Justin M. Keyes
parent
3aa95ef27e
commit
ed424655be
@@ -878,7 +878,9 @@ static int command_line_execute(VimState *state, int key)
|
||||
}
|
||||
|
||||
if (s->c == cedit_key || s->c == K_CMDWIN) {
|
||||
if (ex_normal_busy == 0 && got_int == false) {
|
||||
// TODO(vim): why is ex_normal_busy checked here?
|
||||
if ((s->c == K_CMDWIN || ex_normal_busy == 0)
|
||||
&& got_int == false) {
|
||||
// Open a window to edit the command line (and history).
|
||||
s->c = open_cmdwin();
|
||||
s->some_key_typed = true;
|
||||
|
||||
@@ -750,3 +750,8 @@ func Test_cmdline_overstrike()
|
||||
|
||||
let &encoding = encoding_save
|
||||
endfunc
|
||||
|
||||
func Test_cmdwin_feedkeys()
|
||||
" This should not generate E488
|
||||
call feedkeys("q:\<CR>", 'x')
|
||||
endfunc
|
||||
|
||||
Reference in New Issue
Block a user