X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Flibmarklin%2Ftrain.h;h=319119b93828fd745639a7a37b8c1ae3d6a69794;hb=59e4c75da550e96ae74162a5ed70e8b1999721d8;hp=f9ea6f17ae0001b39432e8cd83b57ac8fb4cf9ce;hpb=77f8c0e033b9b5e7085de5d22a62128a996a5b2a;p=r2c2.git diff --git a/source/libmarklin/train.h b/source/libmarklin/train.h index f9ea6f1..319119b 100644 --- a/source/libmarklin/train.h +++ b/source/libmarklin/train.h @@ -12,15 +12,14 @@ Distributed under the GPL #include #include #include "block.h" +#include "controller.h" namespace Marklin { -class ControlModel; class Route; class Timetable; class Vehicle; class VehicleType; -struct TrainControl; class Train: public sigc::trackable { @@ -79,7 +78,7 @@ private: std::list cur_blocks; std::list rsv_blocks; Block *pending_block; - ControlModel *control; + Controller *controller; Timetable *timetable; bool active; unsigned current_speed; @@ -110,7 +109,7 @@ public: const std::string &get_name() const { return name; } void set_priority(int); int get_priority() const { return priority; } - ControlModel &get_control_model() const { return *control; } + Controller &get_controller() const { return *controller; } void add_vehicle(const VehicleType &); void remove_vehicle(unsigned); @@ -145,7 +144,7 @@ public: void save(std::list &) const; private: - void control_changed(const TrainControl &); + void control_changed(const Controller::Control &); void loco_speed_event(unsigned, unsigned, bool); void loco_func_event(unsigned, unsigned, bool); void sensor_event(unsigned, bool);