diff options
author | Erich Eckner <git@eckner.net> | 2018-10-30 11:13:12 +0100 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2018-10-30 15:28:03 +0100 |
commit | a34d095259409cf1454d9777deabbc00bcdb9407 (patch) | |
tree | 9e7c37ed33f5bd6b3c2f41cf248dcb656b2a4afa /src/vehicle_gui.h | |
parent | 6647cb917963c4e0d6d633b7a92af78167050893 (diff) | |
download | openttd-underground-plus-others-original.tar.xz |
underground patch appliedunderground-plus-others-original
Diffstat (limited to 'src/vehicle_gui.h')
-rw-r--r-- | src/vehicle_gui.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/vehicle_gui.h b/src/vehicle_gui.h index 83e098dcd..c3b702fc8 100644 --- a/src/vehicle_gui.h +++ b/src/vehicle_gui.h @@ -18,6 +18,7 @@ #include "station_type.h" #include "engine_type.h" #include "company_type.h" +#include <list> void ShowVehicleRefitWindow(const Vehicle *v, VehicleOrderID order, Window *parent, bool auto_refit = false); @@ -37,6 +38,22 @@ enum VehicleInvalidateWindowData { VIWD_AUTOREPLACE = -4, ///< Autoreplace replaced the vehicle. }; +/** List item for one destination. */ +struct CargoDestSummaryData { + SourceID dest; ///< Destination ID + SourceType type; ///< Destination type + uint count; ///< Cargo count + + CargoDestSummaryData(SourceID dest, SourceType type, uint count) + : dest(dest), type(type), count(count) + { } +}; + +/** List of cargo amounts grouped by final destination. */ +typedef std::list<CargoDestSummaryData> CargoDestSummary; + +void AddVehicleCargoDestSummary(const Vehicle *v, CargoDestSummary *sum); + int DrawVehiclePurchaseInfo(int left, int right, int y, EngineID engine_number); void DrawTrainImage(const Train *v, int left, int right, int y, VehicleID selection, EngineImageType image_type, int skip, VehicleID drag_dest = INVALID_VEHICLE); |