Docking: Fixed node->HasCloseButton not honoring ImGuiDockNodeFlags_NoCloseButton in a floating node, leading to empty space at the right of tab-bars with those flags. (#2109)

This commit is contained in:
omar
2019-11-22 22:13:52 +01:00
parent 3895363432
commit 106184bbea
2 changed files with 2 additions and 2 deletions

View File

@ -12329,7 +12329,7 @@ static void ImGui::DockNodeUpdate(ImGuiDockNode* node)
{
// [Automatic root or child nodes]
node->EnableCloseButton = false;
node->HasCloseButton = (node->Windows.Size > 0) && (node_flags & ImGuiDockNodeFlags_NoWindowMenuButton) == 0;
node->HasCloseButton = (node->Windows.Size > 0) && (node_flags & ImGuiDockNodeFlags_NoCloseButton) == 0;
node->HasWindowMenuButton = (node->Windows.Size > 0) && (node_flags & ImGuiDockNodeFlags_NoWindowMenuButton) == 0;
for (int window_n = 0; window_n < node->Windows.Size; window_n++)
{