| 1321 | CargoDataVector displayed_rows{}; ///< Parent entry of currently displayed rows (including collapsed ones). |
| 1322 | |
| 1323 | StationViewWindow(WindowDesc &desc, WindowNumber window_number) : Window(desc) |
| 1324 | { |
| 1325 | this->CreateNestedTree(); |
| 1326 | this->GetWidget<NWidgetStacked>(WID_SV_CLOSE_AIRPORT_SEL)->SetDisplayedPlane(Station::Get(window_number)->facilities.Test(StationFacility::Airport) ? 0 : SZSP_NONE); |
| 1327 | this->vscroll = this->GetScrollbar(WID_SV_SCROLLBAR); |
| 1328 | /* Nested widget tree creation is done in two steps to ensure that this->GetWidget<NWidgetCore>(WID_SV_ACCEPTS_RATINGS) exists in UpdateWidgetSize(). */ |
| 1329 | this->FinishInitNested(window_number); |
| 1330 | |
| 1331 | this->groupings[0] = GR_CARGO; |
| 1332 | this->sortings[0] = CargoSortType::AsGrouping; |
| 1333 | this->SelectGroupBy(_settings_client.gui.station_gui_group_order); |
| 1334 | this->SelectSortBy(_settings_client.gui.station_gui_sort_by); |
| 1335 | this->sort_orders[0] = SO_ASCENDING; |
| 1336 | this->SelectSortOrder((SortOrder)_settings_client.gui.station_gui_sort_order); |
| 1337 | this->owner = Station::Get(window_number)->owner; |
| 1338 | } |
| 1339 | |
| 1340 | void OnInit() override |
| 1341 | { |
nothing calls this directly
no test coverage detected