mirror of
https://github.com/neovim/neovim.git
synced 2025-09-11 22:08:18 +00:00
vim-patch:8.1.0064: typing CTRL-W in a prompt buffer shows mode "-- --"
Problem: Typing CTRL-W in a prompt buffer shows mode "-- --". Solution: Set restart_edit to 'A' and check for it.942b4541a2
Nvim already checked for 'i' in showmode(), so this bug was fixed with <C-W> (though this patch now changes <C-W> to use 'A'). However, the missing changes I ported for v8.1.0036 use 'A' when a callback leaves the window in insert mode and edit gets restarted, so this bug was possible there. Modify showmode() restart_edit condition to match v8.2.1978:957cf67d50
This commit is contained in:
@@ -2240,6 +2240,9 @@ static void leaving_window(win_T *const win)
|
||||
// When leaving a prompt window stop Insert mode and perhaps restart
|
||||
// it when entering that window again.
|
||||
win->w_buffer->b_prompt_insert = restart_edit;
|
||||
if (restart_edit != NUL && mode_displayed) {
|
||||
clear_cmdline = true; // unshow mode later
|
||||
}
|
||||
restart_edit = NUL;
|
||||
|
||||
// When leaving the window (or closing the window) was done from a
|
||||
|
Reference in New Issue
Block a user