diff options
author | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2021-05-10 18:32:26 -0400 |
---|---|---|
committer | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2021-05-10 18:32:26 -0400 |
commit | 7af26e51168445cb6675453684d74b0d1f74df67 (patch) | |
tree | c3bdf82c11e09bd9c1b219d36e1c76243c35577b /src | |
parent | 133351cbf80d620513eb6eb1b63eae15312eaeed (diff) | |
download | rneovim-7af26e51168445cb6675453684d74b0d1f74df67.tar.gz rneovim-7af26e51168445cb6675453684d74b0d1f74df67.tar.bz2 rneovim-7af26e51168445cb6675453684d74b0d1f74df67.zip |
Revert "api/window: use the "noblock" variants in nvim_win_set_buf"
This reverts commit 1def3d1542d6a65f057e743faea39a760b50db87.
Plugins may depend on catching the following events
when creating windows:
- BufWinEnter
- BufEnter
- BufLeave
Risky to introduce this breaking change on 0.5 release
when 0.5 release should be out by now.
https://github.com/asvetliakov/vscode-neovim/issues/632#issuecomment-837201224
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/api/window.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/api/window.c b/src/nvim/api/window.c index 158e149628..f942d6b19f 100644 --- a/src/nvim/api/window.c +++ b/src/nvim/api/window.c @@ -54,7 +54,7 @@ void nvim_win_set_buf(Window window, Buffer buffer, Error *err) return; } - if (switch_win_noblock(&save_curwin, &save_curtab, win, tab, false) == FAIL) { + if (switch_win(&save_curwin, &save_curtab, win, tab, false) == FAIL) { api_set_error(err, kErrorTypeException, "Failed to switch to window %d", @@ -74,7 +74,7 @@ void nvim_win_set_buf(Window window, Buffer buffer, Error *err) // So do it now. validate_cursor(); - restore_win_noblock(save_curwin, save_curtab, false); + restore_win(save_curwin, save_curtab, false); } /// Gets the (1,0)-indexed cursor position in the window. |api-indexing| |