MCPcopy Create free account
hub / github.com/SatDump/SatDump / TableFixColumnSortDirection

Method TableFixColumnSortDirection

src-core/imgui/imgui_tables.cpp:2723–2729  ·  view source on GitHub ↗

Fix sort direction if currently set on a value which is unavailable (e.g. activating NoSortAscending/NoSortDescending)

Source from the content-addressed store, hash-verified

2721
2722// Fix sort direction if currently set on a value which is unavailable (e.g. activating NoSortAscending/NoSortDescending)
2723void ImGui::TableFixColumnSortDirection(ImGuiTable* table, ImGuiTableColumn* column)
2724{
2725 if (column->SortOrder == -1 || (column->SortDirectionsAvailMask & (1 << column->SortDirection)) != 0)
2726 return;
2727 column->SortDirection = (ImU8)TableGetColumnAvailSortDirection(column, 0);
2728 table->IsSortSpecsDirty = true;
2729}
2730
2731// Calculate next sort direction that would be set after clicking the column
2732// - If the PreferSortDescending flag is set, we will default to a Descending direction on the first click.

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected