]> granicus.if.org Git - vim/commitdiff
patch 8.2.2874: MS-Windows: screen redraws too often v8.2.2874
authormatveyt <matthewtarasov@gmail.com>
Thu, 20 May 2021 09:54:10 +0000 (11:54 +0200)
committerBram Moolenaar <Bram@vim.org>
Thu, 20 May 2021 09:54:10 +0000 (11:54 +0200)
Problem:    MS-Windows: screen redraws too often.
Solution:   Do not redraw when peeking for a character. (closes #8230,
            closes #8211)

src/os_win32.c
src/version.c

index a743e714b7dc3f59023f64d85bfe788f33749391..8a1ed72d7c0cd13201a7f595de6afc66bde2b9ef 100644 (file)
@@ -1648,7 +1648,9 @@ WaitForChar(long msec, int ignore_input)
        peek_console_input(g_hConIn, &ir, 1, &cRecords);
 
 # ifdef FEAT_MBYTE_IME
-       if (State & CMDLINE && msg_row == Rows - 1)
+       // May have to redraw if the cursor ends up in the wrong place.
+       // Only when not peeking.
+       if (State & CMDLINE && msg_row == Rows - 1 && msec != 0)
        {
            CONSOLE_SCREEN_BUFFER_INFO csbi;
 
index 7fd43382267768755c45bc555a341c739bf6bf2f..7f163f8a3c7cbd3d51b7c3d2f2d80da2305c548b 100644 (file)
@@ -750,6 +750,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    2874,
 /**/
     2873,
 /**/