From 1b964e850bbe3207fe9a65849520634955d141f0 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 29 Jan 2010 04:01:29 +0000 Subject: Send binding information to client. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2392 a436a847-0d15-0410-975c-d299462d15a1 --- src/client/ClientStore.cpp | 9 +++++++++ src/client/ClientStore.hpp | 3 ++- src/client/SigClientInterface.hpp | 4 ++++ src/client/ThreadedSigClientInterface.hpp | 6 ++++++ 4 files changed, 21 insertions(+), 1 deletion(-) (limited to 'src/client') diff --git a/src/client/ClientStore.cpp b/src/client/ClientStore.cpp index 73d2b23e..40c11323 100644 --- a/src/client/ClientStore.cpp +++ b/src/client/ClientStore.cpp @@ -17,6 +17,7 @@ #include "raul/log.hpp" #include "raul/PathTable.hpp" +#include "interface/MessageType.hpp" #include "ClientStore.hpp" #include "ObjectModel.hpp" #include "PatchModel.hpp" @@ -53,6 +54,7 @@ ClientStore::ClientStore(SharedPtr engine, SharedPtrsignal_port_value.connect(sigc::mem_fun(this, &ClientStore::set_port_value)); emitter->signal_voice_value.connect(sigc::mem_fun(this, &ClientStore::set_voice_value)); emitter->signal_activity.connect(sigc::mem_fun(this, &ClientStore::activity)); + emitter->signal_binding.connect(sigc::mem_fun(this, &ClientStore::binding)); } @@ -383,6 +385,13 @@ ClientStore::activity(const Path& path) } +void +ClientStore::binding(const Path& path, const Shared::MessageType& type) +{ + LOG(info) << "Bind " << path << " : " << type << endl; +} + + SharedPtr ClientStore::connection_patch(const Path& src_port_path, const Path& dst_port_path) { diff --git a/src/client/ClientStore.hpp b/src/client/ClientStore.hpp index ba32b362..63b03dae 100644 --- a/src/client/ClientStore.hpp +++ b/src/client/ClientStore.hpp @@ -33,7 +33,7 @@ namespace Raul { class Atom; } namespace Ingen { -namespace Shared { class GraphObject; } +namespace Shared { class GraphObject; class MessageType; } namespace Client { @@ -96,6 +96,7 @@ private: // Slots for SigClientInterface signals void object_moved(const Raul::Path& old_path, const Raul::Path& new_path); void activity(const Raul::Path& path); + void binding(const Raul::Path& path, const Shared::MessageType& type); bool attempt_connection(const Raul::Path& src_port_path, const Raul::Path& dst_port_path); diff --git a/src/client/SigClientInterface.hpp b/src/client/SigClientInterface.hpp index 785f6ac8..3a3ce9d4 100644 --- a/src/client/SigClientInterface.hpp +++ b/src/client/SigClientInterface.hpp @@ -60,6 +60,7 @@ public: sigc::signal signal_port_value; sigc::signal signal_voice_value; sigc::signal signal_activity; + sigc::signal signal_binding; /** Fire pending signals. Only does anything on derived classes (that may queue) */ virtual bool emit_signals() { return false; } @@ -114,6 +115,9 @@ protected: void activity(const Raul::Path& port_path) { EMIT(activity, port_path); } + + void binding(const Raul::Path& path, const Shared::MessageType& type) + { EMIT(binding, path, type); } }; diff --git a/src/client/ThreadedSigClientInterface.hpp b/src/client/ThreadedSigClientInterface.hpp index 901fd4a6..456aa67f 100644 --- a/src/client/ThreadedSigClientInterface.hpp +++ b/src/client/ThreadedSigClientInterface.hpp @@ -24,6 +24,7 @@ #include #include "raul/Atom.hpp" #include "interface/ClientInterface.hpp" +#include "interface/MessageType.hpp" #include "SigClientInterface.hpp" #include "raul/SRSWQueue.hpp" @@ -60,6 +61,7 @@ public: , property_change_slot(signal_property_change.make_slot()) , port_value_slot(signal_port_value.make_slot()) , activity_slot(signal_activity.make_slot()) + , binding_slot(signal_binding.make_slot()) { } @@ -110,6 +112,9 @@ public: void activity(const Raul::Path& port_path) { push_sig(sigc::bind(activity_slot, port_path)); } + void binding(const Raul::Path& path, const Shared::MessageType& type) + { push_sig(sigc::bind(binding_slot, path, type)); } + /** Process all queued events - Called from GTK thread to emit signals. */ bool emit_signals(); @@ -139,6 +144,7 @@ private: sigc::slot port_value_slot; sigc::slot voice_value_slot; sigc::slot activity_slot; + sigc::slot binding_slot; }; -- cgit v1.2.1