X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Fardour%2Fcontrol_protocol_manager.h;h=6fedc95c6c679bb309d69d8a79bc9c67a9d39d88;hb=aae367b63c9b619db1e40f27dc334c6987219481;hp=f315744e508256a545f5b5d4cbdb885f13b0c34e;hpb=c221b09560842b71773eee15972d87c222baf6a1;p=ardour.git diff --git a/libs/ardour/ardour/control_protocol_manager.h b/libs/ardour/ardour/control_protocol_manager.h index f315744e50..6fedc95c6c 100644 --- a/libs/ardour/ardour/control_protocol_manager.h +++ b/libs/ardour/ardour/control_protocol_manager.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2000-2007 Paul Davis + Copyright (C) 2000-2007 Paul Davis This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -23,11 +23,11 @@ #include #include -#include #include -#include "pbd/stateful.h" +#include "pbd/stateful.h" +#include "ardour/session_handle.h" namespace ARDOUR { @@ -49,16 +49,16 @@ struct ControlProtocolInfo { ~ControlProtocolInfo() { if (state) { delete state; } } }; - class ControlProtocolManager : public sigc::trackable, public PBD::Stateful +class ControlProtocolManager : public PBD::Stateful, public ARDOUR::SessionHandlePtr { public: ~ControlProtocolManager (); static ControlProtocolManager& instance(); - void set_session (Session&); + void set_session (Session*); void discover_control_protocols (); - void foreach_known_protocol (sigc::slot); + void foreach_known_protocol (boost::function); void load_mandatory_protocols (); ControlProtocol* instantiate (ControlProtocolInfo&); @@ -70,18 +70,17 @@ struct ControlProtocolInfo { void set_protocol_states (const XMLNode&); - int set_state (const XMLNode&); + int set_state (const XMLNode&, int version); XMLNode& get_state (void); private: ControlProtocolManager (); static ControlProtocolManager* _instance; - Session* _session; Glib::Mutex protocols_lock; std::list control_protocols; - void drop_session (); + void session_going_away (); int control_protocol_discover (std::string path); ControlProtocolDescriptor* get_descriptor (std::string path);