0
0
mirror of https://github.com/vim/vim.git synced 2025-09-25 03:54:15 -04:00

patch 8.2.4591: cursor line not updated when a callback moves the cursor

Problem:    Cursor line not updated when a callback moves the cursor.
Solution:   Check if the cursor moved. (closes #9970)
This commit is contained in:
Bram Moolenaar
2022-03-19 11:10:15 +00:00
parent 2995e5cf4e
commit e7a74d5375
6 changed files with 66 additions and 10 deletions

View File

@@ -1386,12 +1386,7 @@ main_loop(
#ifdef FEAT_SYN_HL
// Might need to update for 'cursorline'.
// When 'cursorlineopt' is "screenline" need to redraw always.
if (curwin->w_p_cul
&& (curwin->w_last_cursorline != curwin->w_cursor.lnum
|| (curwin->w_p_culopt_flags & CULOPT_SCRLINE))
&& !char_avail())
redraw_later(VALID);
check_redraw_cursorline();
#endif
if (VIsual_active)
update_curbuf(INVERTED); // update inverted part