summaryrefslogtreecommitdiff
path: root/src/station_gui.cpp
diff options
context:
space:
mode:
authorbjarni <bjarni@openttd.org>2007-01-21 00:01:47 +0000
committerbjarni <bjarni@openttd.org>2007-01-21 00:01:47 +0000
commitc8c27b974058e5c6673ed7a7d0bdd2eb623d4295 (patch)
tree8c1a71e7972a3d2f2e3847db25fc4cf7a81aca7f /src/station_gui.cpp
parent470619a8bb960501bf54d82cb3a1c2a9f7006768 (diff)
downloadopenttd-c8c27b974058e5c6673ed7a7d0bdd2eb623d4295.tar.xz
(svn r8293) -Codechange: overloaded ShowVehicleListWindow() so it can open all types of vehicle lists (depending on arguments)
- Also removed some unneeded arguments - this also allows removing an if-else cascade in ShowVehicleListWindowLocal()
Diffstat (limited to 'src/station_gui.cpp')
-rw-r--r--src/station_gui.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/station_gui.cpp b/src/station_gui.cpp
index b11a44090..fee50bba6 100644
--- a/src/station_gui.cpp
+++ b/src/station_gui.cpp
@@ -762,13 +762,13 @@ static void StationViewWndProc(Window *w, WindowEvent *e)
case 10: { /* Show a list of scheduled trains to this station */
const Station *st = GetStation(w->window_number);
- ShowVehicleListWindow(st->owner, w->window_number, VEH_Train);
+ ShowVehicleListWindow(st->owner, VEH_Train, (StationID)w->window_number);
break;
}
case 11: { /* Show a list of scheduled road-vehicles to this station */
const Station *st = GetStation(w->window_number);
- ShowVehicleListWindow(st->owner, w->window_number, VEH_Road);
+ ShowVehicleListWindow(st->owner, VEH_Road, (StationID)w->window_number);
break;
}
@@ -776,7 +776,7 @@ static void StationViewWndProc(Window *w, WindowEvent *e)
const Station *st = GetStation(w->window_number);
/* Since oilrigs have no owners, show the scheduled aircraft of current player */
PlayerID owner = (st->owner == OWNER_NONE) ? _current_player : st->owner;
- ShowVehicleListWindow(owner, w->window_number, VEH_Aircraft);
+ ShowVehicleListWindow(owner, VEH_Aircraft, (StationID)w->window_number);
break;
}
@@ -784,7 +784,7 @@ static void StationViewWndProc(Window *w, WindowEvent *e)
const Station *st = GetStation(w->window_number);
/* Since oilrigs/bouys have no owners, show the scheduled ships of current player */
PlayerID owner = (st->owner == OWNER_NONE) ? _current_player : st->owner;
- ShowVehicleListWindow(owner, w->window_number, VEH_Ship);
+ ShowVehicleListWindow(owner, VEH_Ship, (StationID)w->window_number);
break;
}
}