diff options
author | David Robillard <d@drobilla.net> | 2008-07-28 22:14:12 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2008-07-28 22:14:12 +0000 |
commit | 2fd41e8d03877f454bff4943901d5c1638aac9bb (patch) | |
tree | 12699bceae6b9bf2bf33059c133ec2b86ab738b7 /src/libs/engine/events/SetPortValueEvent.hpp | |
parent | a6fb6a0289ea47692d87f3e0200532a426f8e60d (diff) | |
download | ingen-2fd41e8d03877f454bff4943901d5c1638aac9bb.tar.gz ingen-2fd41e8d03877f454bff4943901d5c1638aac9bb.tar.bz2 ingen-2fd41e8d03877f454bff4943901d5c1638aac9bb.zip |
Remove near duplicate SetPortValueEvent and SetPortValueQueuedEvent classes.
git-svn-id: http://svn.drobilla.net/lad/ingen@1294 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/libs/engine/events/SetPortValueEvent.hpp')
-rw-r--r-- | src/libs/engine/events/SetPortValueEvent.hpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/libs/engine/events/SetPortValueEvent.hpp b/src/libs/engine/events/SetPortValueEvent.hpp index d814a55b..6f89fc20 100644 --- a/src/libs/engine/events/SetPortValueEvent.hpp +++ b/src/libs/engine/events/SetPortValueEvent.hpp @@ -19,7 +19,7 @@ #define SETPORTVALUEEVENT_H #include <string> -#include "Event.hpp" +#include "QueuedEvent.hpp" #include "types.hpp" using std::string; @@ -29,14 +29,20 @@ class PortImpl; /** An event to change the value of a port. + * + * This event can either be queued or immediate, depending on the queued + * parameter passed to the constructor. It must be passed to the appropriate + * place (ie queued event passed to the event queue and non-queued event + * processed in the audio thread) or nasty things will happen. * * \ingroup engine */ -class SetPortValueEvent : public Event +class SetPortValueEvent : public QueuedEvent { public: SetPortValueEvent(Engine& engine, SharedPtr<Responder> responder, + bool queued, SampleCount timestamp, const string& port_path, const string& data_type, @@ -45,6 +51,7 @@ public: SetPortValueEvent(Engine& engine, SharedPtr<Responder> responder, + bool queued, SampleCount timestamp, uint32_t voice_num, const string& port_path, @@ -54,12 +61,14 @@ public: ~SetPortValueEvent(); + void pre_process(); void execute(ProcessContext& context); void post_process(); private: enum ErrorType { NO_ERROR, PORT_NOT_FOUND, NO_SPACE }; + bool _queued; bool _omni; uint32_t _voice_num; const string _port_path; |