Codechange: Rename window related DeleteXXX to match new behaviour

This commit is contained in:
glx22
2021-05-17 15:46:38 +02:00
committed by Loïc Guilloux
parent 994bf19aef
commit 5799402f7a
63 changed files with 253 additions and 253 deletions

View File

@@ -843,11 +843,11 @@ void Vehicle::PreDestructor()
}
if (this->IsPrimaryVehicle()) {
DeleteWindowById(WC_VEHICLE_VIEW, this->index);
DeleteWindowById(WC_VEHICLE_ORDERS, this->index);
DeleteWindowById(WC_VEHICLE_REFIT, this->index);
DeleteWindowById(WC_VEHICLE_DETAILS, this->index);
DeleteWindowById(WC_VEHICLE_TIMETABLE, this->index);
CloseWindowById(WC_VEHICLE_VIEW, this->index);
CloseWindowById(WC_VEHICLE_ORDERS, this->index);
CloseWindowById(WC_VEHICLE_REFIT, this->index);
CloseWindowById(WC_VEHICLE_DETAILS, this->index);
CloseWindowById(WC_VEHICLE_TIMETABLE, this->index);
SetWindowDirty(WC_COMPANY, this->owner);
OrderBackup::ClearVehicle(this);
}
@@ -2795,7 +2795,7 @@ void Vehicle::RemoveFromShared()
if (this->orders.list->GetNumVehicles() == 1) {
/* When there is only one vehicle, remove the shared order list window. */
DeleteWindowById(GetWindowClassForVehicleType(this->type), vli.Pack());
CloseWindowById(GetWindowClassForVehicleType(this->type), vli.Pack());
InvalidateVehicleOrder(this->FirstShared(), VIWD_MODIFY_ORDERS);
} else if (were_first) {
/* If we were the first one, update to the new first one.