diff options
author | David Robillard <d@drobilla.net> | 2012-03-16 03:15:41 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-03-16 03:15:41 +0000 |
commit | 119468f621a59d86da10bedf75c4427b70f9d370 (patch) | |
tree | f15ea3f345d43b37d492096876c483543fcc1426 /src/server/ServerInterfaceImpl.cpp | |
parent | 0b93e39af34d3af361f35d510224fda4fda56071 (diff) | |
download | ingen-119468f621a59d86da10bedf75c4427b70f9d370.tar.gz ingen-119468f621a59d86da10bedf75c4427b70f9d370.tar.bz2 ingen-119468f621a59d86da10bedf75c4427b70f9d370.zip |
Remove activity from interface and use set_property() instead.
Move client registration stuff to Engine and remove corresponding events.
Simply response ID interface.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4066 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/server/ServerInterfaceImpl.cpp')
-rw-r--r-- | src/server/ServerInterfaceImpl.cpp | 34 |
1 files changed, 8 insertions, 26 deletions
diff --git a/src/server/ServerInterfaceImpl.cpp b/src/server/ServerInterfaceImpl.cpp index eb615e9a..1bd388ec 100644 --- a/src/server/ServerInterfaceImpl.cpp +++ b/src/server/ServerInterfaceImpl.cpp @@ -21,6 +21,7 @@ #include "ingen/shared/URIs.hpp" +#include "ClientBroadcaster.hpp" #include "Driver.hpp" #include "Engine.hpp" #include "EventSource.hpp" @@ -63,37 +64,18 @@ ServerInterfaceImpl::now() const } void -ServerInterfaceImpl::respond_to(ClientInterface* client, int32_t id) +ServerInterfaceImpl::set_response_id(int32_t id) { - _request_client = client; - _request_id = id; -} - -void -ServerInterfaceImpl::disable_responses() -{ - _request_client = NULL; - _request_id = -1; + if (!_request_client) { // Kludge + _request_client = _engine.broadcaster()->client( + "http://drobilla.net/ns/ingen#internal"); + std::cerr << "SET REQUEST CLIENT " << (void*)_request_client << std::endl; + } + _request_id = id; } /* *** ServerInterface implementation below here *** */ -void -ServerInterfaceImpl::register_client(ClientInterface* client) -{ - push_queued(new Events::RegisterClient(_engine, client, _request_id, now(), client->uri())); - _request_client = client; - _request_id = 1; -} - -void -ServerInterfaceImpl::unregister_client(const URI& uri) -{ - push_queued(new Events::UnregisterClient(_engine, _request_client, _request_id, now(), uri)); - _request_client = NULL; - _request_id = -1; -} - // Bundle commands void |