X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Flibmarklin%2Fturnout.h;h=616a7fedb3bcabddef78cd9dc52c56ea0a6185b1;hb=7839b7c3d782abb5c98a24d51cae109407068c02;hp=dbb689e5f8cfb00d67a011f135bcb034b1b31c49;hpb=1d735b80482317fd930eb47ca255ab9f1f120a7d;p=r2c2.git diff --git a/source/libmarklin/turnout.h b/source/libmarklin/turnout.h index dbb689e..616a7fe 100644 --- a/source/libmarklin/turnout.h +++ b/source/libmarklin/turnout.h @@ -1,3 +1,10 @@ +/* $Id$ + +This file is part of the MSP Märklin suite +Copyright © 2006-2009 Mikkosoft Productions, Mikko Rasa +Distributed under the GPL +*/ + #ifndef LIBMARKLIN_TURNOUT_H_ #define LIBMARKLIN_TURNOUT_H_ @@ -10,6 +17,7 @@ namespace Marklin { class Control; +class Reply; class Turnout { @@ -17,18 +25,20 @@ private: Control &control; unsigned addr; unsigned route; + bool dual; public: + sigc::signal signal_route_changing; sigc::signal signal_route_changed; - Turnout(Control &, unsigned); + Turnout(Control &, unsigned, bool =false); void set_route(unsigned); unsigned get_address() const { return addr; } unsigned get_route() const { return route; } private: void command(bool); - void status_reply(Error, const std::string &); + void status_reply(const Reply &, bool); bool switch_timeout(); void turnout_event(unsigned, bool); };