vim-patch:8.1.0002: :stopinsert changes the message position

Problem:    :stopinsert changes the message position.
Solution:   Save and restore msg_col and msg_row in clearmode(). (Jason
            Franklin)
2abad54ced
This commit is contained in:
Jan Edmund Lazo
2019-06-03 23:13:32 -04:00
parent 233a173226
commit 5f41ca4013
2 changed files with 27 additions and 0 deletions

View File

@@ -6595,6 +6595,9 @@ void unshowmode(bool force)
// Clear the mode message.
void clearmode(void)
{
const int save_msg_row = msg_row;
const int save_msg_col = msg_col;
msg_ext_ui_flush();
msg_pos_mode();
if (reg_recording != 0) {
@@ -6602,6 +6605,9 @@ void clearmode(void)
}
msg_clr_eos();
msg_ext_flush_showmode();
msg_col = save_msg_col;
msg_row = save_msg_row;
}
static void recording_mode(int attr)