Skip to content

Commit

Permalink
patch 8.0.1380: using "vim -r swapfile" the hit-enter prompt is mispl…
Browse files Browse the repository at this point in the history
…aced.

Problem:    When recovering a file with "vim -r swapfile" the hit-enter prompt
            is at the top of the window.
Solution:   Invalidate the cursor position.
  • Loading branch information
brammool committed Dec 9, 2017
1 parent e4b78e2 commit 0568431
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/term.c
Original file line number Diff line number Diff line change
Expand Up @@ -3510,6 +3510,9 @@ may_req_ambiguous_char_width(void)
out_str((char_u *)" ");
term_windgoto(0, 0);

/* Need to reset the known cursor position. */
screen_start();

/* check for the characters now, otherwise they might be eaten by
* get_keystroke() */
out_flush();
Expand Down Expand Up @@ -4585,7 +4588,7 @@ check_termcode(
is_mac_terminal = TRUE;
}
# ifdef FEAT_MOUSE_SGR
/* Iterm2 sends 0;95;0 */
/* iTerm2 sends 0;95;0 */
if (STRNCMP(tp + extra - 2, "0;95;0c", 7) == 0)
is_iterm2 = TRUE;
# endif
Expand All @@ -4597,7 +4600,7 @@ check_termcode(
{
# ifdef FEAT_MOUSE_SGR
/* Xterm version 277 supports SGR. Also support
* Terminal.app and iterm2. */
* Terminal.app and iTerm2. */
if (version >= 277 || is_iterm2 || is_mac_terminal)
set_option_value((char_u *)"ttym", 0L,
(char_u *)"sgr", 0);
Expand Down
2 changes: 2 additions & 0 deletions src/version.c
Original file line number Diff line number Diff line change
Expand Up @@ -771,6 +771,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
/**/
1390,
/**/
1379,
/**/
Expand Down

0 comments on commit 0568431

Please sign in to comment.