mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-04 12:08:47 +02:00
Docking: Creating tab bar and adding window into tab bar immediately (not sure why I didn't do that before). Probably broke something subtle, will find out. *Edit* Initially broke restoring selected tab.
This commit is contained in:
@ -6110,10 +6110,11 @@ void ImGui::TabBarRemoveTab(ImGuiTabBar* tab_bar, ImGuiID tab_id)
|
||||
tab_bar->Tabs.erase(tab);
|
||||
if (tab_bar->VisibleTabId == tab_id) { tab_bar->VisibleTabId = 0; }
|
||||
if (tab_bar->WantFocusTabId == tab_id) { tab_bar->WantFocusTabId = 0; }
|
||||
if (tab_bar->SelectedTabId == tab_id) { tab_bar->SelectedTabId = 0; }
|
||||
if (tab_bar->SelectedTabId == tab_id) { tab_bar->SelectedTabId = 0; }
|
||||
if (tab_bar->NextSelectedTabId == tab_id) { tab_bar->NextSelectedTabId = 0; }
|
||||
}
|
||||
|
||||
// Called on manual closure attempt
|
||||
void ImGui::TabBarCloseTab(ImGuiTabBar* tab_bar, ImGuiTabItem* tab)
|
||||
{
|
||||
if ((tab_bar->VisibleTabId == tab->ID) && !(tab->Flags & ImGuiTabItemFlags_UnsavedDocument))
|
||||
|
Reference in New Issue
Block a user