MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / sortNameClick

Method sortNameClick

src/Menu/ListGamesState.cpp:321–337  ·  view source on GitHub ↗

* Sorts the saves by name. * @param action Pointer to an action. */

Source from the content-addressed store, hash-verified

319 * @param action Pointer to an action.
320 */
321void ListGamesState::sortNameClick(Action *)
322{
323 if (_sortable)
324 {
325 if (Options::saveOrder == SORT_NAME_ASC)
326 {
327 Options::saveOrder = SORT_NAME_DESC;
328 }
329 else
330 {
331 Options::saveOrder = SORT_NAME_ASC;
332 }
333 updateArrows();
334 _lstSaves->clearList();
335 sortList(Options::saveOrder);
336 }
337}
338
339/**
340 * Sorts the saves by date.

Callers

nothing calls this directly

Calls 1

clearListMethod · 0.80

Tested by

no test coverage detected