From 3e5fef2e59776923f175a4260adf18c559ab861f Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 1 May 2007 04:01:04 +0000 Subject: Converted Raul (and thus Ingen and Machina) to use Redland over Raptor/Rasqal independently. Fixed patch loading for Ingen (local only, still something wrong with remote...). git-svn-id: http://svn.drobilla.net/lad/ingen@486 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/client/PluginModel.h | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) (limited to 'src/libs/client/PluginModel.h') diff --git a/src/libs/client/PluginModel.h b/src/libs/client/PluginModel.h index d15d0ff4..aba4d1cf 100644 --- a/src/libs/client/PluginModel.h +++ b/src/libs/client/PluginModel.h @@ -48,17 +48,7 @@ public: , _name(name) { set_type_from_uri(type_uri); -#ifdef HAVE_SLV2 - static SLV2Plugins plugins = NULL; - - if (!_slv2_world) { - _slv2_world = slv2_world_new(); - slv2_world_load_all(_slv2_world); - plugins = slv2_world_get_all_plugins(_slv2_world); - } - - _slv2_plugin = slv2_plugins_get_by_uri(plugins, uri.c_str()); -#endif + _slv2_plugin = slv2_plugins_get_by_uri(_slv2_plugins, uri.c_str()); } Type type() const { return _type; } @@ -108,6 +98,12 @@ public: #ifdef HAVE_SLV2 SLV2Plugin slv2_plugin() { return _slv2_plugin; } static SLV2World slv2_world() { return _slv2_world; } + + static void set_slv2_world(SLV2World world) { + _slv2_world = world; + slv2_world_load_all(_slv2_world); + _slv2_plugins = slv2_world_get_all_plugins(_slv2_world); + } #endif private: @@ -116,7 +112,9 @@ private: string _name; #ifdef HAVE_SLV2 - static SLV2World _slv2_world; + static SLV2World _slv2_world; + static SLV2Plugins _slv2_plugins; + SLV2Plugin _slv2_plugin; #endif }; -- cgit v1.2.1