MCPcopy Create free account
hub / github.com/Overload-Technologies/Overload / SetItemSelected

Method SetItemSelected

Dependencies/ImGui/src/imgui_widgets.cpp:8162–8167  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

8160}
8161
8162void ImGuiSelectionBasicStorage::SetItemSelected(ImGuiID id, bool selected)
8163{
8164 int* p_int = _Storage.GetIntRef(id, 0);
8165 if (selected && *p_int == 0) { *p_int = _SelectionOrder++; Size++; }
8166 else if (!selected && *p_int != 0) { *p_int = 0; Size--; }
8167}
8168
8169// Optimized for batch edits (with same value of 'selected')
8170static void ImGuiSelectionBasicStorage_BatchSetItemSelected(ImGuiSelectionBasicStorage* selection, ImGuiID id, bool selected, int size_before_amends, int selection_order)

Calls 1

GetIntRefMethod · 0.80

Tested by

no test coverage detected