mirror of
https://github.com/neovim/neovim.git
synced 2025-09-14 07:18:17 +00:00
vim-patch:8.0.1160: getting tab-local variable fails after closing window
Problem: Getting tab-local variable fails after closing window.
Solution: set tp_firstwin and tp_lastwin. (Jason Franklin, closes vim/vim#2170)
816968defc
This commit is contained in:
@@ -3970,18 +3970,20 @@ win_remove (
|
||||
tabpage_T *tp /* tab page "win" is in, NULL for current */
|
||||
)
|
||||
{
|
||||
if (wp->w_prev != NULL)
|
||||
if (wp->w_prev != NULL) {
|
||||
wp->w_prev->w_next = wp->w_next;
|
||||
else if (tp == NULL)
|
||||
firstwin = wp->w_next;
|
||||
else
|
||||
} else if (tp == NULL) {
|
||||
firstwin = curtab->tp_firstwin = wp->w_next;
|
||||
} else {
|
||||
tp->tp_firstwin = wp->w_next;
|
||||
if (wp->w_next != NULL)
|
||||
}
|
||||
if (wp->w_next != NULL) {
|
||||
wp->w_next->w_prev = wp->w_prev;
|
||||
else if (tp == NULL)
|
||||
lastwin = wp->w_prev;
|
||||
else
|
||||
} else if (tp == NULL) {
|
||||
lastwin = curtab->tp_lastwin = wp->w_prev;
|
||||
} else {
|
||||
tp->tp_lastwin = wp->w_prev;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user