Mercurial > vim
diff src/move.c @ 29275:281509f1417b v8.2.5155
patch 8.2.5155: in diff mode windows may get out of sync
Commit: https://github.com/vim/vim/commit/a315ce1f326b836167ca8b1037dafd93eb8d4d4e
Author: Bram Moolenaar <Bram@vim.org>
Date: Fri Jun 24 12:38:57 2022 +0100
patch 8.2.5155: in diff mode windows may get out of sync
Problem: In diff mode windows may get out of sync. (Gary Johnson)
Solution: Avoid that the other window scrolls for 'cursorbind'.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Fri, 24 Jun 2022 13:45:04 +0200 |
parents | da56650de132 |
children | d97b2ce26258 |
line wrap: on
line diff
--- a/src/move.c +++ b/src/move.c @@ -2952,7 +2952,12 @@ do_check_cursorbind(void) restart_edit_save = restart_edit; restart_edit = TRUE; check_cursor(); - validate_cursor(); + + // Avoid a scroll here for the cursor position, 'scrollbind' is + // more important. + if (!curwin->w_p_scb) + validate_cursor(); + restart_edit = restart_edit_save; // Correct cursor for multi-byte character. if (has_mbyte)