From 0b4967992a18e36c6da6fdbb8ce10fad7176ce2b Mon Sep 17 00:00:00 2001 From: ocornut Date: Thu, 19 Mar 2026 16:29:03 +0100 Subject: [PATCH] MultiSelect: Box-Select: removed now seemingly unnecessary 'selected==false' check, which will also prevent implementation of ImGuiMultiSelectFlags_SelectOnClickAlways. (#9307) We enter into the block either though navigation, and then the Mouse check fails, either through mouse, and then Selected==false is tested above. Amend f904a6646. --- imgui_widgets.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/imgui_widgets.cpp b/imgui_widgets.cpp index f39469c45..e39d614ec 100644 --- a/imgui_widgets.cpp +++ b/imgui_widgets.cpp @@ -8293,7 +8293,7 @@ void ImGui::MultiSelectItemFooter(ImGuiID id, bool* p_selected, bool* p_pressed) // Box-select ImGuiInputSource input_source = (g.NavJustMovedToId == id || g.NavActivateId == id) ? g.NavInputSource : ImGuiInputSource_Mouse; if (flags & (ImGuiMultiSelectFlags_BoxSelect1d | ImGuiMultiSelectFlags_BoxSelect2d)) - if (selected == false && !g.BoxSelectState.IsActive && !g.BoxSelectState.IsStarting && input_source == ImGuiInputSource_Mouse && g.IO.MouseClickedCount[0] == 1) + if (!g.BoxSelectState.IsActive && !g.BoxSelectState.IsStarting && input_source == ImGuiInputSource_Mouse && g.IO.MouseClickedCount[0] == 1) BoxSelectPreStartDrag(ms->BoxSelectId, item_data); //----------------------------------------------------------------------------------------