mirror of https://github.com/OpenTTD/OpenTTD
Compare commits
No commits in common. "a0c6259e3356d73b47dceb99594abd9a67a7b377" and "6b586dddad06a50a115a5ab1db81a9791067fd39" have entirely different histories.
a0c6259e33
...
6b586dddad
|
@ -1323,7 +1323,7 @@ struct BuildVehicleWindow : Window {
|
|||
void SelectEngine(EngineID engine)
|
||||
{
|
||||
CargoID cargo = this->cargo_filter[this->cargo_filter_criteria];
|
||||
if (cargo == CF_ANY || cargo == CF_ENGINES || cargo == CF_NONE) cargo = CT_INVALID;
|
||||
if (cargo == CF_ANY) cargo = CF_NONE;
|
||||
|
||||
this->sel_engine = engine;
|
||||
this->SetBuyVehicleText();
|
||||
|
@ -1647,7 +1647,7 @@ struct BuildVehicleWindow : Window {
|
|||
EngineID sel_eng = this->sel_engine;
|
||||
if (sel_eng != INVALID_ENGINE) {
|
||||
CargoID cargo = this->cargo_filter[this->cargo_filter_criteria];
|
||||
if (cargo == CF_ANY || cargo == CF_ENGINES || cargo == CF_NONE) cargo = CT_INVALID;
|
||||
if (cargo == CF_ANY || cargo == CF_ENGINES) cargo = CF_NONE;
|
||||
if (this->vehicle_type == VEH_TRAIN && RailVehInfo(sel_eng)->railveh_type == RAILVEH_WAGON) {
|
||||
Command<CMD_BUILD_VEHICLE>::Post(GetCmdBuildVehMsg(this->vehicle_type), CcBuildWagon, this->window_number, sel_eng, true, cargo, INVALID_CLIENT_ID);
|
||||
} else {
|
||||
|
|
|
@ -358,6 +358,9 @@ public:
|
|||
this->group_rename = INVALID_GROUP;
|
||||
this->group_over = INVALID_GROUP;
|
||||
|
||||
this->BuildVehicleList();
|
||||
this->SortVehicleList();
|
||||
|
||||
this->groups.ForceRebuild();
|
||||
this->groups.NeedResort();
|
||||
this->BuildGroupList(vli.company);
|
||||
|
@ -374,9 +377,6 @@ public:
|
|||
|
||||
this->FinishInitNested(window_number);
|
||||
this->owner = vli.company;
|
||||
|
||||
this->BuildVehicleList();
|
||||
this->SortVehicleList();
|
||||
}
|
||||
|
||||
~VehicleGroupWindow()
|
||||
|
|
|
@ -1624,11 +1624,10 @@ public:
|
|||
this->industries.SetListing(this->last_sorting);
|
||||
this->industries.SetSortFuncs(IndustryDirectoryWindow::sorter_funcs);
|
||||
this->industries.ForceRebuild();
|
||||
this->BuildSortIndustriesList();
|
||||
|
||||
this->FinishInitNested(0);
|
||||
|
||||
this->BuildSortIndustriesList();
|
||||
|
||||
this->querystrings[WID_ID_FILTER] = &this->industry_editbox;
|
||||
this->industry_editbox.cancel_button = QueryString::ACTION_CLEAR;
|
||||
}
|
||||
|
|
|
@ -1842,6 +1842,9 @@ public:
|
|||
|
||||
this->vscroll = this->GetScrollbar(WID_VL_SCROLLBAR);
|
||||
|
||||
this->BuildVehicleList();
|
||||
this->SortVehicleList();
|
||||
|
||||
/* Set up the window widgets */
|
||||
this->GetWidget<NWidgetCore>(WID_VL_LIST)->tool_tip = STR_VEHICLE_LIST_TRAIN_LIST_TOOLTIP + this->vli.vtype;
|
||||
|
||||
|
@ -1860,9 +1863,6 @@ public:
|
|||
|
||||
this->FinishInitNested(window_number);
|
||||
if (this->vli.company != OWNER_NONE) this->owner = this->vli.company;
|
||||
|
||||
this->BuildVehicleList();
|
||||
this->SortVehicleList();
|
||||
}
|
||||
|
||||
~VehicleListWindow()
|
||||
|
|
Loading…
Reference in New Issue