diff options
author | David Robillard <d@drobilla.net> | 2009-05-28 18:20:58 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2009-05-28 18:20:58 +0000 |
commit | 939a16ee56b4ba58246a98afda203f714d7d17c8 (patch) | |
tree | 47cd29428bc7d277e9956c4488217fb9d756caac /src | |
parent | 8935cca8706d74f39d3cca43b4df3ab48799b06a (diff) | |
download | ingen-939a16ee56b4ba58246a98afda203f714d7d17c8.tar.gz ingen-939a16ee56b4ba58246a98afda203f714d7d17c8.tar.bz2 ingen-939a16ee56b4ba58246a98afda203f714d7d17c8.zip |
Load symbol from LV2 data if available.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2030 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src')
-rw-r--r-- | src/client/ClientStore.cpp | 3 | ||||
-rw-r--r-- | src/client/PluginModel.cpp | 4 | ||||
-rw-r--r-- | src/client/PluginModel.hpp | 5 |
3 files changed, 8 insertions, 4 deletions
diff --git a/src/client/ClientStore.cpp b/src/client/ClientStore.cpp index e4cd604e..0079010c 100644 --- a/src/client/ClientStore.cpp +++ b/src/client/ClientStore.cpp @@ -278,8 +278,7 @@ ClientStore::put(const URI& uri, const Resource::Properties& properties) if (!(is_path || is_meta)) { const URI& type_uri = properties.find("rdf:type")->second.get_uri(); - SharedPtr<PluginModel> p(new PluginModel(uri, type_uri)); - p->set_properties(properties); + SharedPtr<PluginModel> p(new PluginModel(uri, type_uri, properties)); add_plugin(p); return; } diff --git a/src/client/PluginModel.cpp b/src/client/PluginModel.cpp index fd484df4..0627326d 100644 --- a/src/client/PluginModel.cpp +++ b/src/client/PluginModel.cpp @@ -38,10 +38,12 @@ SLV2Plugins PluginModel::_slv2_plugins = NULL; Redland::World* PluginModel::_rdf_world = NULL; -PluginModel::PluginModel(const URI& uri, const URI& type_uri) +PluginModel::PluginModel(const URI& uri, const URI& type_uri, const Resource::Properties& properties) : ResourceImpl(uri) , _type(type_from_uri(_rdf_world->prefixes().qualify(type_uri.str()))) { + add_properties(properties); + Glib::Mutex::Lock lock(_rdf_world->mutex()); assert(_rdf_world); add_property("rdf:type", Raul::Atom(Raul::Atom::URI, this->type_uri())); diff --git a/src/client/PluginModel.hpp b/src/client/PluginModel.hpp index 19499be0..bc7271b9 100644 --- a/src/client/PluginModel.hpp +++ b/src/client/PluginModel.hpp @@ -46,7 +46,10 @@ class PluginModel : public Ingen::Shared::Plugin , public Ingen::Shared::ResourceImpl { public: - PluginModel(const Raul::URI& uri, const Raul::URI& type_uri); + PluginModel( + const Raul::URI& uri, + const Raul::URI& type_uri, + const Shared::Resource::Properties& properties); Type type() const { return _type; } |