Codechange: Pass reference instead of pointer to GUI*Lists. (#10822)

Pointer-avoidance.
This commit is contained in:
PeterN
2023-05-14 09:17:44 +01:00
committed by GitHub
parent 23ce42ad91
commit 64930c343a
6 changed files with 23 additions and 23 deletions

View File

@@ -195,10 +195,10 @@ class ReplaceVehicleWindow : public Window {
this->sel_engine[side] = selected_engine; // update which engine we selected (the same or none, if it's not in the list anymore)
if (draw_left) {
EngList_Sort(&list, &EngineNumberSorter);
EngList_Sort(list, &EngineNumberSorter);
} else {
_engine_sort_direction = this->descending_sort_order;
EngList_Sort(&list, _engine_sort_functions[this->window_number][this->sort_criteria]);
EngList_Sort(list, _engine_sort_functions[this->window_number][this->sort_criteria]);
}
this->engines[side].clear();