(svn r19957) -Codechange: remove VLW_WAYPOINT_LIST

This commit is contained in:
smatz
2010-06-11 00:18:28 +00:00
parent 8bf4a7d1ae
commit c4175b752a
6 changed files with 19 additions and 54 deletions

View File

@@ -35,6 +35,16 @@ BaseStation::~BaseStation()
{
free(this->name);
free(this->speclist);
if (CleaningPool()) return;
Owner owner = this->owner;
if (!Company::IsValidID(owner)) owner = _local_company;
WindowNumber wno = (this->index << 16) | VLW_STATION_LIST | owner;
DeleteWindowById(WC_TRAINS_LIST, wno | (VEH_TRAIN << 11));
DeleteWindowById(WC_ROADVEH_LIST, wno | (VEH_ROAD << 11));
DeleteWindowById(WC_SHIPS_LIST, wno | (VEH_SHIP << 11));
DeleteWindowById(WC_AIRCRAFT_LIST, wno | (VEH_AIRCRAFT << 11));
}
Station::Station(TileIndex tile) :
@@ -83,14 +93,6 @@ Station::~Station()
DeleteWindowById(WC_STATION_VIEW, index);
Owner owner = this->owner;
if (!Company::IsValidID(owner)) owner = _local_company;
WindowNumber wno = (this->index << 16) | VLW_STATION_LIST | owner;
DeleteWindowById(WC_TRAINS_LIST, wno | (VEH_TRAIN << 11));
DeleteWindowById(WC_ROADVEH_LIST, wno | (VEH_ROAD << 11));
DeleteWindowById(WC_SHIPS_LIST, wno | (VEH_SHIP << 11));
DeleteWindowById(WC_AIRCRAFT_LIST, wno | (VEH_AIRCRAFT << 11));
/* Now delete all orders that go to the station */
RemoveOrderFromAllVehicles(OT_GOTO_STATION, this->index);