aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/normal.c
diff options
context:
space:
mode:
authorJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2019-07-20 19:32:17 -0400
committerJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2019-07-20 19:34:06 -0400
commit54d9ea61ab2e7ce0d1dfdbf427b6d6702f972d74 (patch)
treef8a02843a1dac1b7a76eee1456bc1ddd95b1c673 /src/nvim/normal.c
parent526dbcafd1cd3eae24e7c615aadef3555b6791aa (diff)
downloadrneovim-54d9ea61ab2e7ce0d1dfdbf427b6d6702f972d74.tar.gz
rneovim-54d9ea61ab2e7ce0d1dfdbf427b6d6702f972d74.tar.bz2
rneovim-54d9ea61ab2e7ce0d1dfdbf427b6d6702f972d74.zip
vim-patch:8.1.0856: when scrolling a window the cursorline is not always updated
Problem: When scrolling a window other than the current one the cursorline highlighting is not always updated. (Jason Franklin) Solution: Call redraw_for_cursorline() after scrolling. Only set w_last_cursorline when drawing the cursor line. Reset the lines to be redrawn also when redrawing the whole window. https://github.com/vim/vim/commit/bbb5f8d4c2cbc5f48556008875f57cbe7fc4ac6c
Diffstat (limited to 'src/nvim/normal.c')
-rw-r--r--src/nvim/normal.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/nvim/normal.c b/src/nvim/normal.c
index 83853302b4..d33c5d33bb 100644
--- a/src/nvim/normal.c
+++ b/src/nvim/normal.c
@@ -4038,6 +4038,9 @@ static void nv_mousescroll(cmdarg_T *cap)
} else {
mouse_scroll_horiz(cap->arg);
}
+ if (curwin != old_curwin && curwin->w_p_cul) {
+ redraw_for_cursorline(curwin);
+ }
curwin->w_redr_status = true;