aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/nvim/ex_cmds_defs.h2
-rw-r--r--src/nvim/ex_getln.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/src/nvim/ex_cmds_defs.h b/src/nvim/ex_cmds_defs.h
index 5b647ff69a..8a2ebe2cd4 100644
--- a/src/nvim/ex_cmds_defs.h
+++ b/src/nvim/ex_cmds_defs.h
@@ -124,7 +124,7 @@ struct exarg {
LineGetter getline; ///< Function used to get the next line
void *cookie; ///< argument for getline()
struct condstack *cstack; ///< condition stack for ":if" etc.
- bool is_live; ///< live preview
+ bool is_live; ///< 'inccommand' live preview
};
#define FORCE_BIN 1 // ":edit ++bin file"
diff --git a/src/nvim/ex_getln.c b/src/nvim/ex_getln.c
index 07b50a8056..04e7d2fbcf 100644
--- a/src/nvim/ex_getln.c
+++ b/src/nvim/ex_getln.c
@@ -1592,10 +1592,11 @@ static int command_line_changed(CommandLineState *s)
redrawcmdline();
s->did_incsearch = true;
} else if (s->firstc == ':'
+ && KeyTyped // only if interactive
&& *p_icm != NUL // 'inccommand' is set
&& cmdline_star == 0 // not typing a password
&& cmd_is_live(ccline.cmdbuff)) {
- // process a "live" command
+ // process a "live" command ('inccommand')
do_cmdline(ccline.cmdbuff, NULL, NULL, DOCMD_KEEPLINE|DOCMD_LIVE);
redrawcmdline();
}