(svn r15336) -Fix: do not use _current_company in the GUI as there are no guarantees that _current_company is the same as _local_company.

This commit is contained in:
rubidium
2009-02-04 16:45:07 +00:00
parent 09fca459a7
commit 7da743a0dc
14 changed files with 18 additions and 18 deletions

View File

@@ -952,16 +952,16 @@ struct StationViewWindow : public Window {
case SVW_PLANES: { // Show a list of scheduled aircraft to this station
const Station *st = GetStation(this->window_number);
/* Since oilrigs have no owners, show the scheduled aircraft of current company */
Owner owner = (st->owner == OWNER_NONE) ? _current_company : st->owner;
/* Since oilrigs have no owners, show the scheduled aircraft of local company */
Owner owner = (st->owner == OWNER_NONE) ? _local_company : st->owner;
ShowVehicleListWindow(owner, VEH_AIRCRAFT, (StationID)this->window_number);
break;
}
case SVW_SHIPS: { // Show a list of scheduled ships to this station
const Station *st = GetStation(this->window_number);
/* Since oilrigs/bouys have no owners, show the scheduled ships of current company */
Owner owner = (st->owner == OWNER_NONE) ? _current_company : st->owner;
/* Since oilrigs/bouys have no owners, show the scheduled ships of local company */
Owner owner = (st->owner == OWNER_NONE) ? _local_company : st->owner;
ShowVehicleListWindow(owner, VEH_SHIP, (StationID)this->window_number);
break;
}