From 787a309445d18db5823857c0fb43268f4d1b2efe Mon Sep 17 00:00:00 2001 From: omar Date: Wed, 22 Jan 2020 17:04:54 +0100 Subject: [PATCH] Tables: Fixed headers closing popups. --- imgui_tables.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/imgui_tables.cpp b/imgui_tables.cpp index 87eb64fe..0f3475bb 100644 --- a/imgui_tables.cpp +++ b/imgui_tables.cpp @@ -1979,7 +1979,7 @@ void ImGui::TableHeader(const char* label) // Keep header highlighted when context menu is open. (FIXME-TABLE: however we cannot assume the ID of said popup if it has been created by the user...) const bool selected = (table->IsContextPopupOpen && table->ContextPopupColumn == column_n && table->InstanceInteracted == table->InstanceNo); - const bool pressed = Selectable("", selected, ImGuiSelectableFlags_DrawHoveredWhenHeld, ImVec2(0.0f, label_height)); + const bool pressed = Selectable("", selected, ImGuiSelectableFlags_DrawHoveredWhenHeld | ImGuiSelectableFlags_DontClosePopups, ImVec2(0.0f, label_height)); const bool held = IsItemActive(); if (held) table->HeldHeaderColumn = (ImS8)column_n;