MCPcopy Create free account
hub / github.com/KebsCS/KBotExt / TableGcCompactTransientBuffers

Method TableGcCompactTransientBuffers

KBotExt/imgui/imgui_tables.cpp:3548–3561  ·  view source on GitHub ↗

Free up/compact internal Table buffers for when it gets unused

Source from the content-addressed store, hash-verified

3546
3547// Free up/compact internal Table buffers for when it gets unused
3548void ImGui::TableGcCompactTransientBuffers(ImGuiTable* table)
3549{
3550 //IMGUI_DEBUG_PRINT("TableGcCompactTransientBuffers() id=0x%08X\n", table->ID);
3551 ImGuiContext& g = *GImGui;
3552 IM_ASSERT(table->MemoryCompacted == false);
3553 table->SortSpecs.Specs = NULL;
3554 table->SortSpecsMulti.clear();
3555 table->IsSortSpecsDirty = true; // FIXME: In theory shouldn't have to leak into user performing a sort on resume.
3556 table->ColumnsNames.clear();
3557 table->MemoryCompacted = true;
3558 for (int n = 0; n < table->ColumnsCount; n++)
3559 table->Columns[n].NameOffset = -1;
3560 g.TablesLastTimeActive[g.Tables.GetIndex(table)] = -1.0f;
3561}
3562
3563void ImGui::TableGcCompactTransientBuffers(ImGuiTableTempData* temp_data)
3564{

Callers

nothing calls this directly

Calls 3

GetIndexMethod · 0.80
ClearFreeMemoryMethod · 0.80
clearMethod · 0.45

Tested by

no test coverage detected