mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-07 21:39:54 +02:00
Docking: Fixed restoring of tab order within a dockspace or a split node.
(tests in "docking_tab_order")
This commit is contained in:
@ -15464,9 +15464,9 @@ void ImGui::BeginDocked(ImGuiWindow* window, bool* p_open)
|
||||
else
|
||||
window->Flags &= ~ImGuiWindowFlags_NoTitleBar; // Clear the NoTitleBar flag in case the user set it: confusingly enough we need a title bar height so we are correctly offset, but it won't be displayed!
|
||||
|
||||
// Save new dock order only if the tab bar has been visible once.
|
||||
// Save new dock order only if the window has been visible once already
|
||||
// This allows multiple windows to be created in the same frame and have their respective dock orders preserved.
|
||||
if (node->TabBar && node->TabBar->CurrFrameVisible != -1)
|
||||
if (node->TabBar && window->WasActive)
|
||||
window->DockOrder = (short)DockNodeGetTabOrder(window);
|
||||
|
||||
if ((node->WantCloseAll || node->WantCloseTabId == window->ID) && p_open != NULL)
|
||||
|
Reference in New Issue
Block a user