aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ex_getln.c
diff options
context:
space:
mode:
authorJit <gelguy@gmail.com>2019-05-26 19:52:30 +0200
committerJustin M. Keyes <justinkz@gmail.com>2019-05-26 19:52:30 +0200
commit0bbaef8a99af8733cc64ff29858e17c19ed30b3c (patch)
tree988d75711bdcc8ff3d1447f75bcd607200dcdbc8 /src/nvim/ex_getln.c
parentfc7861f0faf907fba4cd0259bc3e8665f3df473b (diff)
downloadrneovim-0bbaef8a99af8733cc64ff29858e17c19ed30b3c.tar.gz
rneovim-0bbaef8a99af8733cc64ff29858e17c19ed30b3c.tar.bz2
rneovim-0bbaef8a99af8733cc64ff29858e17c19ed30b3c.zip
UI/cmdline: check if redraw is needed after K_EVENT, K_COMMAND #9804
fixes #8490
Diffstat (limited to 'src/nvim/ex_getln.c')
-rw-r--r--src/nvim/ex_getln.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/nvim/ex_getln.c b/src/nvim/ex_getln.c
index beac3cd9ec..7b020a240e 100644
--- a/src/nvim/ex_getln.c
+++ b/src/nvim/ex_getln.c
@@ -547,7 +547,10 @@ static int command_line_execute(VimState *state, int key)
} else {
do_cmdline(NULL, getcmdkeycmd, NULL, DOCMD_NOWAIT);
}
- redrawcmdline();
+
+ if (!cmdline_was_last_drawn) {
+ redrawcmdline();
+ }
return 1;
}
@@ -3457,6 +3460,8 @@ void redrawcmd(void)
return;
}
+ redrawing_cmdline = true;
+
msg_start();
redrawcmdprompt();
@@ -3478,9 +3483,11 @@ void redrawcmd(void)
*/
msg_scroll = FALSE; /* next message overwrites cmdline */
- /* Typing ':' at the more prompt may set skip_redraw. We don't want this
- * in cmdline mode */
- skip_redraw = FALSE;
+ // Typing ':' at the more prompt may set skip_redraw. We don't want this
+ // in cmdline mode.
+ skip_redraw = false;
+
+ redrawing_cmdline = false;
}
void compute_cmdrow(void)