From: Bram Moolenaar Date: Sun, 16 Jul 2017 13:24:01 +0000 (+0200) Subject: patch 8.0.0720: unfinished mapping not displayed when running timer X-Git-Tag: v8.0.0720 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6a77d2667e982655f6adacee774ee7aa2581bd8a;p=vim patch 8.0.0720: unfinished mapping not displayed when running timer Problem: Unfinished mapping not displayed when running timer. Solution: Also use the extra_char while waiting for a mapping and digraph. (closes #1844) --- diff --git a/src/ex_getln.c b/src/ex_getln.c index afdf0b4c9..894756da2 100644 --- a/src/ex_getln.c +++ b/src/ex_getln.c @@ -54,6 +54,8 @@ static int new_cmdpos; /* position set by set_cmdline_pos() */ static int extra_char = NUL; /* extra character to display when redrawing * the command line */ +static int extra_char_shift; + #ifdef FEAT_CMDHIST typedef struct hist_entry { @@ -1175,7 +1177,6 @@ getcmdline( dont_scroll = TRUE; /* disallow scrolling here */ #endif putcmdline('"', TRUE); - extra_char = '"'; ++no_mapping; i = c = plain_vgetc(); /* CTRL-R */ if (i == Ctrl_O) @@ -1759,7 +1760,6 @@ getcmdline( ignore_drag_release = TRUE; #endif putcmdline('^', TRUE); - extra_char = '^'; c = get_literal(); /* get next (two) character(s) */ do_abbr = FALSE; /* don't do abbreviation now */ extra_char = NUL; @@ -1780,7 +1780,6 @@ getcmdline( ignore_drag_release = TRUE; #endif putcmdline('?', TRUE); - extra_char = '?'; #ifdef USE_ON_FLY_SCROLL dont_scroll = TRUE; /* disallow scrolling here */ #endif @@ -2945,6 +2944,8 @@ putcmdline(int c, int shift) draw_cmdline(ccline.cmdpos, ccline.cmdlen - ccline.cmdpos); msg_no_more = FALSE; cursorcmd(); + extra_char = c; + extra_char_shift = shift; } /* @@ -2967,6 +2968,7 @@ unputcmdline(void) draw_cmdline(ccline.cmdpos, 1); msg_no_more = FALSE; cursorcmd(); + extra_char = NUL; } /* @@ -3418,7 +3420,7 @@ redrawcmd(void) set_cmdspos_cursor(); if (extra_char != NUL) - putcmdline(extra_char, TRUE); + putcmdline(extra_char, extra_char_shift); /* * An emsg() before may have set msg_scroll. This is used in normal mode, diff --git a/src/version.c b/src/version.c index bd274f730..0d5db7f00 100644 --- a/src/version.c +++ b/src/version.c @@ -769,6 +769,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 720, /**/ 719, /**/