mirror of
https://github.com/neovim/neovim.git
synced 2025-09-19 01:38:16 +00:00
Merge pull request #6619 from bfredl/floating
Floating windows in TUI and Remote UI
This commit is contained in:
@@ -6279,6 +6279,9 @@ void tabpage_close(int forceit)
|
||||
{
|
||||
// First close all the windows but the current one. If that worked then
|
||||
// close the last window in this tab, that will close it.
|
||||
while (curwin->w_floating) {
|
||||
ex_win_close(forceit, curwin, NULL);
|
||||
}
|
||||
if (!ONE_WINDOW) {
|
||||
close_others(true, forceit);
|
||||
}
|
||||
@@ -6303,8 +6306,8 @@ void tabpage_close_other(tabpage_T *tp, int forceit)
|
||||
/* Limit to 1000 windows, autocommands may add a window while we close
|
||||
* one. OK, so I'm paranoid... */
|
||||
while (++done < 1000) {
|
||||
sprintf((char *)prev_idx, "%i", tabpage_index(tp));
|
||||
wp = tp->tp_firstwin;
|
||||
snprintf((char *)prev_idx, sizeof(prev_idx), "%i", tabpage_index(tp));
|
||||
wp = tp->tp_lastwin;
|
||||
ex_win_close(forceit, wp, tp);
|
||||
|
||||
/* Autocommands may delete the tab page under our fingers and we may
|
||||
@@ -6325,6 +6328,7 @@ static void ex_only(exarg_T *eap)
|
||||
{
|
||||
win_T *wp;
|
||||
int wnr;
|
||||
|
||||
if (eap->addr_count > 0) {
|
||||
wnr = eap->line2;
|
||||
for (wp = firstwin; --wnr > 0;) {
|
||||
@@ -6333,6 +6337,10 @@ static void ex_only(exarg_T *eap)
|
||||
else
|
||||
wp = wp->w_next;
|
||||
}
|
||||
} else {
|
||||
wp = curwin;
|
||||
}
|
||||
if (wp != curwin) {
|
||||
win_goto(wp);
|
||||
}
|
||||
close_others(TRUE, eap->forceit);
|
||||
|
Reference in New Issue
Block a user