diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-11-20 08:38:46 +0800 |
---|---|---|
committer | zeertzjq <zeertzjq@outlook.com> | 2022-11-20 21:11:37 +0800 |
commit | 035d41ac5e5fcbb49eb64b72a924c4d6f89f0579 (patch) | |
tree | 4f461e40c21bfe0e3ec488f91c55d599b317681d /src/nvim/normal.c | |
parent | 822eabc5e123bca71ba945467c3b01110bb0e003 (diff) | |
download | rneovim-035d41ac5e5fcbb49eb64b72a924c4d6f89f0579.tar.gz rneovim-035d41ac5e5fcbb49eb64b72a924c4d6f89f0579.tar.bz2 rneovim-035d41ac5e5fcbb49eb64b72a924c4d6f89f0579.zip |
vim-patch:partial:9.0.0913: only change in current window triggers the WinScrolled event
Problem: Only a change in the current window triggers the WinScrolled
event.
Solution: Trigger WinScrolled if any window scrolled or changed size.
(issue vim/vim#11576)
https://github.com/vim/vim/commit/0a60f79fd0c328b47b36279a95282e9f8d9e7512
Skip locking of window layout and E1312.
Copy the latest version of all WinScrolled tests from Vim.
Note: patch 9.0.0915 is needed for the Lua tests to pass.
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'src/nvim/normal.c')
-rw-r--r-- | src/nvim/normal.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/nvim/normal.c b/src/nvim/normal.c index ed689df91c..8207710b6b 100644 --- a/src/nvim/normal.c +++ b/src/nvim/normal.c @@ -1397,6 +1397,9 @@ static int normal_check(VimState *state) fclose(time_fd); time_fd = NULL; } + // After the first screen update may start triggering WinScrolled + // autocmd events. Store all the scroll positions and sizes now. + may_make_initial_scroll_size_snapshot(); } // May perform garbage collection when waiting for a character, but |