0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 8.0.1504: Win32: the screen may be cleared on startup

Problem:    Win32: the screen may be cleared on startup.
Solution:   Only call shell_resized() when the size actually changed. (Ken
            Takata, closes #2527)
This commit is contained in:
Bram Moolenaar
2018-02-11 16:40:45 +01:00
parent cdd09aa51a
commit c33ecb2915
2 changed files with 9 additions and 1 deletions

View File

@@ -1557,7 +1557,13 @@ WaitForChar(long msec, int ignore_input)
if (ir.EventType == FOCUS_EVENT) if (ir.EventType == FOCUS_EVENT)
handle_focus_event(ir); handle_focus_event(ir);
else if (ir.EventType == WINDOW_BUFFER_SIZE_EVENT) else if (ir.EventType == WINDOW_BUFFER_SIZE_EVENT)
{
/* Only call shell_resized() when the size actually change to
* avoid the screen is cleard. */
if (ir.Event.WindowBufferSizeEvent.dwSize.X != Columns
|| ir.Event.WindowBufferSizeEvent.dwSize.Y != Rows)
shell_resized(); shell_resized();
}
#ifdef FEAT_MOUSE #ifdef FEAT_MOUSE
else if (ir.EventType == MOUSE_EVENT else if (ir.EventType == MOUSE_EVENT
&& decode_mouse_event(&ir.Event.MouseEvent)) && decode_mouse_event(&ir.Event.MouseEvent))

View File

@@ -771,6 +771,8 @@ static char *(features[]) =
static int included_patches[] = static int included_patches[] =
{ /* Add new patch number below this line */ { /* Add new patch number below this line */
/**/
1504,
/**/ /**/
1503, 1503,
/**/ /**/