|
OpenTTD Source
14.0-beta3
|
#include "command_type.h"#include "tilearea_type.h"#include "window_type.h"#include "station_type.h"Go to the source code of this file.
Typedefs | |
| using | StationPickerCmdProc = std::function< bool(bool test, StationID to_join)> |
Enumerations | |
| enum | StationCoverageType { SCT_PASSENGERS_ONLY, SCT_NON_PASSENGERS_ONLY, SCT_ALL } |
| Types of cargo to display for station coverage. More... | |
Functions | |
| int | DrawStationCoverageAreaText (int left, int right, int top, StationCoverageType sct, int rad, bool supplies) |
| Calculates and draws the accepted or supplied cargo around the selected tile(s) More... | |
| void | CheckRedrawStationCoverage (const Window *w) |
| Check whether we need to redraw the station coverage text. More... | |
| void | CheckRedrawWaypointCoverage (const Window *w) |
| void | ShowSelectStationIfNeeded (TileArea ta, StationPickerCmdProc proc) |
| Show the station selection window when needed. More... | |
| void | ShowSelectWaypointIfNeeded (TileArea ta, StationPickerCmdProc proc) |
| Show the waypoint selection window when needed. More... | |
Contains enums and function declarations connected with stations GUI
Definition in file station_gui.h.
| enum StationCoverageType |
Types of cargo to display for station coverage.
| Enumerator | |
|---|---|
| SCT_PASSENGERS_ONLY | Draw only passenger class cargoes. |
| SCT_NON_PASSENGERS_ONLY | Draw all non-passenger class cargoes. |
| SCT_ALL | Draw all cargoes. |
Definition at line 20 of file station_gui.h.
| void CheckRedrawStationCoverage | ( | const Window * | w | ) |
Check whether we need to redraw the station coverage text.
If it is needed actually make the window for redrawing.
| w | the window to check. |
Definition at line 126 of file station_gui.cpp.
References _ctrl_pressed.
Referenced by BuildDocksStationWindow::OnRealtimeTick(), BuildAirportWindow::OnRealtimeTick(), BuildRailStationWindow::OnRealtimeTick(), and BuildRoadStationWindow::OnRealtimeTick().
| int DrawStationCoverageAreaText | ( | int | left, |
| int | right, | ||
| int | top, | ||
| StationCoverageType | sct, | ||
| int | rad, | ||
| bool | supplies | ||
| ) |
Calculates and draws the accepted or supplied cargo around the selected tile(s)
| left | x position where the string is to be drawn |
| right | the right most position to draw on |
| top | y position where the string is to be drawn |
| sct | which type of cargo is to be displayed (passengers/non-passengers) |
| rad | radius around selected tile(s) to be searched |
| supplies | if supplied cargoes should be drawn, else accepted cargoes |
Definition at line 52 of file station_gui.cpp.
References TileVirtXY().
| void ShowSelectStationIfNeeded | ( | TileArea | ta, |
| StationPickerCmdProc | proc | ||
| ) |
Show the station selection window when needed.
If not, build the station.
| ta | Area to build the station in |
| proc | Function called to execute the build command. |
Definition at line 2460 of file station_gui.cpp.
| void ShowSelectWaypointIfNeeded | ( | TileArea | ta, |
| StationPickerCmdProc | proc | ||
| ) |
Show the waypoint selection window when needed.
If not, build the waypoint.
| ta | Area to build the waypoint in |
| proc | Function called to execute the build command. |
Definition at line 2470 of file station_gui.cpp.