diff options
author | David Robillard <d@drobilla.net> | 2008-08-19 18:51:06 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2008-08-19 18:51:06 +0000 |
commit | e16206982d074e62956de00eeef611478f01c430 (patch) | |
tree | 388bc6e5ad9220cf9cdedf865a2d45856f418ae4 /src/libs/client/ClientStore.cpp | |
parent | 14764da12f3808da0c40b643ac8224716f060729 (diff) | |
download | ingen-e16206982d074e62956de00eeef611478f01c430.tar.gz ingen-e16206982d074e62956de00eeef611478f01c430.tar.bz2 ingen-e16206982d074e62956de00eeef611478f01c430.zip |
Preliminary connecting via HTTP in Gtk client.
Better handling of overflowed client event receive buffer.
Store fixes, complain only once about orphans, don't request an orphan parent over and over.
git-svn-id: http://svn.drobilla.net/lad/ingen@1447 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/libs/client/ClientStore.cpp')
-rw-r--r-- | src/libs/client/ClientStore.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/libs/client/ClientStore.cpp b/src/libs/client/ClientStore.cpp index 0597aa21..18582046 100644 --- a/src/libs/client/ClientStore.cpp +++ b/src/libs/client/ClientStore.cpp @@ -72,17 +72,15 @@ ClientStore::add_plugin_orphan(SharedPtr<NodeModel> node) { if (!_handle_orphans) return; - cerr << "WARNING: Node " << node->path() << " received, but plugin " - << node->plugin_uri() << " unknown." << endl; Raul::Table<string, list<SharedPtr<NodeModel> > >::iterator spawn = _plugin_orphans.find(node->plugin_uri()); - _engine->request_plugin(node->plugin_uri()); - if (spawn != _plugin_orphans.end()) { spawn->second.push_back(node); } else { + cerr << "WARNING: Orphans of plugin " << node->plugin_uri() << " received" << endl; + _engine->request_plugin(node->plugin_uri()); list<SharedPtr<NodeModel> > l; l.push_back(node); _plugin_orphans[node->plugin_uri()] = l; @@ -108,7 +106,7 @@ ClientStore::resolve_plugin_orphans(SharedPtr<PluginModel> plugin) for (list<SharedPtr<NodeModel> >::iterator i = spawn.begin(); i != spawn.end(); ++i) { (*i)->_plugin = plugin; - add_object(*i); + //add_object(*i); } } } @@ -248,7 +246,6 @@ ClientStore::add_object(SharedPtr<ObjectModel> object) // one (with precedence to the new values). iterator existing = find(object->path()); if (existing != end()) { - cout << "WARNING: Object " << object->path() << " already exists in store" << endl; PtrCast<ObjectModel>(existing->second)->set(object); } else { @@ -444,6 +441,7 @@ ClientStore::new_node(const string& path, const string& plugin_uri) if (!plug) { SharedPtr<NodeModel> n(new NodeModel(plugin_uri, path)); add_plugin_orphan(n); + add_object(n); } else { SharedPtr<NodeModel> n(new NodeModel(plug, path)); add_object(n); |