diff options
Diffstat (limited to 'src/server/events')
28 files changed, 279 insertions, 303 deletions
diff --git a/src/server/events/Connect.cpp b/src/server/events/Connect.cpp index 44c734a8..6e20be8f 100644 --- a/src/server/events/Connect.cpp +++ b/src/server/events/Connect.cpp @@ -16,6 +16,7 @@ #include "Connect.hpp" +#include "../internals/BlockDelay.hpp" #include "ArcImpl.hpp" #include "BlockImpl.hpp" #include "Broadcaster.hpp" @@ -26,15 +27,16 @@ #include "InputPort.hpp" #include "PortImpl.hpp" #include "PreProcessContext.hpp" -#include "internals/BlockDelay.hpp" #include "types.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Node.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "ingen/paths.hpp" -#include "raul/Maid.hpp" +#include <ingen/Interface.hpp> +#include <ingen/Message.hpp> +#include <ingen/Node.hpp> +#include <ingen/Properties.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <ingen/paths.hpp> +#include <raul/Maid.hpp> #include <cassert> #include <memory> @@ -57,7 +59,7 @@ Connect::~Connect() = default; bool Connect::pre_process(PreProcessContext& ctx) { - std::lock_guard<Store::Mutex> lock(_engine.store()->mutex()); + const std::lock_guard<Store::Mutex> lock{_engine.store()->mutex()}; Node* tail = _engine.store()->get(_msg.tail); if (!tail) { @@ -132,7 +134,7 @@ Connect::pre_process(PreProcessContext& ctx) head_block->providers().insert(tail_block); if (ctx.must_compile(*_graph)) { - if (!(_compiled_graph = compile(*_engine.maid(), *_graph))) { + if (!(_compiled_graph = compile(*_graph))) { head_block->providers().erase(tail_block); tail_block->dependants().erase(head_block); return Event::pre_process_done(Status::COMPILATION_FAILED); @@ -165,7 +167,7 @@ Connect::execute(RunContext& ctx) } _head->connect_buffers(); if (_compiled_graph) { - _graph->set_compiled_graph(std::move(_compiled_graph)); + _compiled_graph = _graph->swap_compiled_graph(std::move(_compiled_graph)); } } } @@ -173,7 +175,7 @@ Connect::execute(RunContext& ctx) void Connect::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS) { _engine.broadcaster()->message(_msg); if (!_tail_remove.empty() || !_tail_add.empty()) { diff --git a/src/server/events/Connect.hpp b/src/server/events/Connect.hpp index a735b68c..458df0ef 100644 --- a/src/server/events/Connect.hpp +++ b/src/server/events/Connect.hpp @@ -21,9 +21,9 @@ #include "PortImpl.hpp" #include "types.hpp" -#include "ingen/Message.hpp" -#include "ingen/Properties.hpp" -#include "raul/Maid.hpp" +#include <ingen/Message.hpp> +#include <ingen/Properties.hpp> +#include <raul/Maid.hpp> #include <memory> @@ -38,8 +38,6 @@ class CompiledGraph; class Engine; class GraphImpl; class InputPort; -class PreProcessContext; -class RunContext; namespace events { @@ -66,7 +64,7 @@ private: const ingen::Connect _msg; GraphImpl* _graph{nullptr}; InputPort* _head{nullptr}; - raul::managed_ptr<CompiledGraph> _compiled_graph; + std::unique_ptr<CompiledGraph> _compiled_graph; std::shared_ptr<ArcImpl> _arc; raul::managed_ptr<PortImpl::Voices> _voices; Properties _tail_remove; diff --git a/src/server/events/Copy.cpp b/src/server/events/Copy.cpp index f6bcc62a..e75bf1c5 100644 --- a/src/server/events/Copy.cpp +++ b/src/server/events/Copy.cpp @@ -14,7 +14,7 @@ along with Ingen. If not, see <http://www.gnu.org/licenses/>. */ -#include "events/Copy.hpp" +#include "Copy.hpp" #include "BlockImpl.hpp" #include "Broadcaster.hpp" @@ -23,16 +23,18 @@ #include "GraphImpl.hpp" #include "PreProcessContext.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Parser.hpp" -#include "ingen/Serialiser.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "ingen/URI.hpp" -#include "ingen/World.hpp" -#include "ingen/paths.hpp" -#include "raul/Path.hpp" -#include "raul/Symbol.hpp" +#include <ingen/Interface.hpp> +#include <ingen/Message.hpp> +#include <ingen/Node.hpp> +#include <ingen/Parser.hpp> +#include <ingen/Serialiser.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <ingen/URI.hpp> +#include <ingen/World.hpp> +#include <ingen/paths.hpp> +#include <raul/Path.hpp> +#include <raul/Symbol.hpp> #include <map> #include <memory> @@ -57,7 +59,7 @@ Copy::~Copy() = default; bool Copy::pre_process(PreProcessContext& ctx) { - std::lock_guard<Store::Mutex> lock(_engine.store()->mutex()); + const std::lock_guard<Store::Mutex> lock{_engine.store()->mutex()}; if (uri_is_path(_msg.old_uri)) { // Old URI is a path within the engine @@ -124,8 +126,7 @@ Copy::engine_to_engine(PreProcessContext& ctx) } // Create new block - if (!(_block = dynamic_cast<BlockImpl*>( - _old_block->duplicate(_engine, raul::Symbol(new_path.symbol()), _parent)))) { + if (!(_block = _old_block->duplicate(_engine, raul::Symbol(new_path.symbol()), _parent))) { return Event::pre_process_done(Status::INTERNAL_ERROR); } @@ -136,7 +137,7 @@ Copy::engine_to_engine(PreProcessContext& ctx) _engine.store()->add(_block); // Compile graph with new block added for insertion in audio thread - _compiled_graph = ctx.maybe_compile(*_engine.maid(), *_parent); + _compiled_graph = ctx.maybe_compile(*_parent); return Event::pre_process_done(Status::SUCCESS); } @@ -163,7 +164,7 @@ Copy::engine_to_filesystem(PreProcessContext&) return Event::pre_process_done(Status::INTERNAL_ERROR); } - std::lock_guard<std::mutex> lock(_engine.world().rdf_mutex()); + const std::lock_guard<std::mutex> lock{_engine.world().rdf_mutex()}; if (ends_with(_msg.new_uri, ".ingen") || ends_with(_msg.new_uri, ".ingen/")) { _engine.world().serialiser()->write_bundle(graph, URI(_msg.new_uri)); @@ -184,7 +185,7 @@ Copy::filesystem_to_engine(PreProcessContext&) return Event::pre_process_done(Status::INTERNAL_ERROR); } - std::lock_guard<std::mutex> lock(_engine.world().rdf_mutex()); + const std::lock_guard<std::mutex> lock{_engine.world().rdf_mutex()}; // Old URI is a filesystem path and new URI is a path within the engine const std::string src_path(_msg.old_uri.path()); @@ -207,14 +208,15 @@ void Copy::execute(RunContext&) { if (_block && _compiled_graph) { - _parent->set_compiled_graph(std::move(_compiled_graph)); + _compiled_graph = + _parent->swap_compiled_graph(std::move(_compiled_graph)); } } void Copy::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS) { _engine.broadcaster()->message(_msg); } diff --git a/src/server/events/Copy.hpp b/src/server/events/Copy.hpp index 8460140a..8031bb42 100644 --- a/src/server/events/Copy.hpp +++ b/src/server/events/Copy.hpp @@ -20,8 +20,7 @@ #include "Event.hpp" #include "types.hpp" -#include "ingen/Message.hpp" -#include "raul/Maid.hpp" +#include <ingen/Message.hpp> #include <memory> @@ -36,7 +35,6 @@ class CompiledGraph; class Engine; class GraphImpl; class PreProcessContext; -class RunContext; namespace events { @@ -67,7 +65,7 @@ private: std::shared_ptr<BlockImpl> _old_block{nullptr}; GraphImpl* _parent{nullptr}; BlockImpl* _block{nullptr}; - raul::managed_ptr<CompiledGraph> _compiled_graph; + std::unique_ptr<CompiledGraph> _compiled_graph; }; } // namespace events diff --git a/src/server/events/CreateBlock.cpp b/src/server/events/CreateBlock.cpp index 73834fcb..55c9b782 100644 --- a/src/server/events/CreateBlock.cpp +++ b/src/server/events/CreateBlock.cpp @@ -28,31 +28,27 @@ #include "State.hpp" #include "types.hpp" -#include "ingen/FilePath.hpp" -#include "ingen/Forge.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Node.hpp" -#include "ingen/Properties.hpp" -#include "ingen/Resource.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "ingen/URI.hpp" -#include "ingen/URIs.hpp" -#include "ingen/World.hpp" -#include "ingen/paths.hpp" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" -#include "raul/Symbol.hpp" +#include <ingen/FilePath.hpp> +#include <ingen/Forge.hpp> +#include <ingen/Interface.hpp> +#include <ingen/Node.hpp> +#include <ingen/Properties.hpp> +#include <ingen/Resource.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <ingen/URI.hpp> +#include <ingen/URIs.hpp> +#include <ingen/World.hpp> +#include <ingen/paths.hpp> +#include <raul/Path.hpp> +#include <raul/Symbol.hpp> #include <map> #include <memory> +#include <string> #include <utility> -namespace ingen::server { - -class RunContext; - -namespace events { +namespace ingen::server::events { CreateBlock::CreateBlock(Engine& engine, const std::shared_ptr<Interface>& client, @@ -169,7 +165,7 @@ CreateBlock::pre_process(PreProcessContext& ctx) /* Compile graph with new block added for insertion in audio thread TODO: Since the block is not connected at this point, a full compilation could be avoided and the block simply appended. */ - _compiled_graph = ctx.maybe_compile(*_engine.maid(), *_graph); + _compiled_graph = ctx.maybe_compile(*_graph); _update.put_block(_block); @@ -180,14 +176,15 @@ void CreateBlock::execute(RunContext&) { if (_status == Status::SUCCESS && _compiled_graph) { - _graph->set_compiled_graph(std::move(_compiled_graph)); + _compiled_graph = + _graph->swap_compiled_graph(std::move(_compiled_graph)); } } void CreateBlock::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS) { _update.send(*_engine.broadcaster()); } @@ -199,5 +196,4 @@ CreateBlock::undo(Interface& target) target.del(_block->uri()); } -} // namespace events -} // namespace ingen::server +} // namespace ingen::server::events diff --git a/src/server/events/CreateBlock.hpp b/src/server/events/CreateBlock.hpp index 2a7a60ab..0ee6e36f 100644 --- a/src/server/events/CreateBlock.hpp +++ b/src/server/events/CreateBlock.hpp @@ -21,8 +21,7 @@ #include "Event.hpp" #include "types.hpp" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" +#include <raul/Path.hpp> #include <cstdint> #include <memory> @@ -38,8 +37,6 @@ class BlockImpl; class CompiledGraph; class Engine; class GraphImpl; -class PreProcessContext; -class RunContext; namespace events { @@ -70,7 +67,7 @@ private: ClientUpdate _update; GraphImpl* _graph{nullptr}; BlockImpl* _block{nullptr}; - raul::managed_ptr<CompiledGraph> _compiled_graph; + std::unique_ptr<CompiledGraph> _compiled_graph; }; } // namespace events diff --git a/src/server/events/CreateGraph.cpp b/src/server/events/CreateGraph.cpp index bcc935bb..5df28afa 100644 --- a/src/server/events/CreateGraph.cpp +++ b/src/server/events/CreateGraph.cpp @@ -14,35 +14,36 @@ along with Ingen. If not, see <http://www.gnu.org/licenses/>. */ -#include "events/CreateGraph.hpp" +#include "CreateGraph.hpp" #include "BlockImpl.hpp" #include "Broadcaster.hpp" #include "CompiledGraph.hpp" +#include "CreatePort.hpp" #include "Engine.hpp" #include "GraphImpl.hpp" #include "PreProcessContext.hpp" -#include "events/CreatePort.hpp" #include "types.hpp" -#include "ingen/Forge.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Node.hpp" -#include "ingen/Resource.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "ingen/URI.hpp" -#include "ingen/URIs.hpp" -#include "ingen/World.hpp" -#include "ingen/paths.hpp" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" -#include "raul/Symbol.hpp" +#include <ingen/Forge.hpp> +#include <ingen/Interface.hpp> +#include <ingen/Node.hpp> +#include <ingen/Properties.hpp> +#include <ingen/Resource.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <ingen/URI.hpp> +#include <ingen/URIs.hpp> +#include <ingen/World.hpp> +#include <ingen/paths.hpp> +#include <raul/Path.hpp> +#include <raul/Symbol.hpp> #include <boost/intrusive/slist.hpp> #include <map> #include <memory> +#include <string> #include <utility> namespace ingen::server::events { @@ -192,7 +193,7 @@ CreateGraph::pre_process(PreProcessContext& ctx) if (_parent->enabled()) { _graph->enable(); } - _compiled_graph = ctx.maybe_compile(*_engine.maid(), *_parent); + _compiled_graph = ctx.maybe_compile(*_parent); } _graph->activate(*_engine.buffer_factory()); @@ -219,7 +220,8 @@ CreateGraph::execute(RunContext& ctx) if (_graph) { if (_parent) { if (_compiled_graph) { - _parent->set_compiled_graph(std::move(_compiled_graph)); + _compiled_graph = + _parent->swap_compiled_graph(std::move(_compiled_graph)); } } else { _engine.set_root_graph(_graph); @@ -235,7 +237,7 @@ CreateGraph::execute(RunContext& ctx) void CreateGraph::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS) { _update.send(*_engine.broadcaster()); } diff --git a/src/server/events/CreateGraph.hpp b/src/server/events/CreateGraph.hpp index 7fc005ad..1d7f04a5 100644 --- a/src/server/events/CreateGraph.hpp +++ b/src/server/events/CreateGraph.hpp @@ -21,9 +21,8 @@ #include "Event.hpp" #include "types.hpp" -#include "ingen/Properties.hpp" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" +#include <ingen/Properties.hpp> +#include <raul/Path.hpp> #include <cstdint> #include <list> @@ -38,8 +37,6 @@ namespace server { class CompiledGraph; class Engine; class GraphImpl; -class PreProcessContext; -class RunContext; namespace events { @@ -74,7 +71,7 @@ private: ClientUpdate _update; GraphImpl* _graph{nullptr}; GraphImpl* _parent{nullptr}; - raul::managed_ptr<CompiledGraph> _compiled_graph; + std::unique_ptr<CompiledGraph> _compiled_graph; std::list<std::unique_ptr<Event>> _child_events; }; diff --git a/src/server/events/CreatePort.cpp b/src/server/events/CreatePort.cpp index 7a01d0d9..b42542f8 100644 --- a/src/server/events/CreatePort.cpp +++ b/src/server/events/CreatePort.cpp @@ -23,26 +23,29 @@ #include "Engine.hpp" #include "GraphImpl.hpp" #include "PortImpl.hpp" - -#include "ingen/Atom.hpp" -#include "ingen/Forge.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Node.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "ingen/URI.hpp" -#include "ingen/URIMap.hpp" -#include "ingen/URIs.hpp" -#include "ingen/World.hpp" -#include "ingen/paths.hpp" -#include "raul/Array.hpp" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" -#include "raul/Symbol.hpp" +#include "PortType.hpp" + +#include <ingen/Atom.hpp> +#include <ingen/Forge.hpp> +#include <ingen/Interface.hpp> +#include <ingen/Node.hpp> +#include <ingen/Properties.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <ingen/URI.hpp> +#include <ingen/URIMap.hpp> +#include <ingen/URIs.hpp> +#include <ingen/World.hpp> +#include <ingen/paths.hpp> +#include <raul/Array.hpp> +#include <raul/Maid.hpp> +#include <raul/Path.hpp> +#include <raul/Symbol.hpp> #include <cassert> #include <map> #include <memory> +#include <string> #include <utility> namespace ingen::server::events { @@ -55,7 +58,6 @@ CreatePort::CreatePort(Engine& engine, const Properties& properties) : Event(engine, client, id, timestamp) , _path(std::move(path)) - , _port_type(PortType::UNKNOWN) , _properties(properties) { const ingen::URIs& uris = _engine.world().uris(); @@ -179,7 +181,7 @@ CreatePort::pre_process(PreProcessContext&) _update = _graph_port->properties(); assert(_graph_port->index() == static_cast<uint32_t>(index_i->second.get<int32_t>())); - assert(_graph->num_ports_non_rt() == static_cast<uint32_t>(old_n_ports) + 1u); + assert(_graph->num_ports_non_rt() == static_cast<uint32_t>(old_n_ports) + 1U); assert(_ports_array->size() == _graph->num_ports_non_rt()); assert(_graph_port->index() < _ports_array->size()); return Event::pre_process_done(Status::SUCCESS); @@ -210,7 +212,7 @@ CreatePort::execute(RunContext& ctx) void CreatePort::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS) { _engine.broadcaster()->put(path_to_uri(_path), _update); } diff --git a/src/server/events/CreatePort.hpp b/src/server/events/CreatePort.hpp index 6d3e9ca2..151bf82f 100644 --- a/src/server/events/CreatePort.hpp +++ b/src/server/events/CreatePort.hpp @@ -22,10 +22,10 @@ #include "PortType.hpp" #include "types.hpp" -#include "ingen/Properties.hpp" -#include "lv2/urid/urid.h" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" +#include <ingen/Properties.hpp> +#include <lv2/urid/urid.h> +#include <raul/Maid.hpp> +#include <raul/Path.hpp> #include <cstdint> #include <memory> @@ -41,8 +41,6 @@ class DuplexPort; class Engine; class EnginePort; class GraphImpl; -class PreProcessContext; -class RunContext; namespace events { @@ -72,7 +70,7 @@ private: }; raul::Path _path; - PortType _port_type; + PortType _port_type{PortType::UNKNOWN}; LV2_URID _buf_type{0}; GraphImpl* _graph{nullptr}; DuplexPort* _graph_port{nullptr}; diff --git a/src/server/events/Delete.cpp b/src/server/events/Delete.cpp index b64c81c0..9e940ea7 100644 --- a/src/server/events/Delete.cpp +++ b/src/server/events/Delete.cpp @@ -30,18 +30,18 @@ #include "PortImpl.hpp" #include "PreProcessContext.hpp" -#include "ingen/Forge.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Node.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "ingen/URI.hpp" -#include "ingen/URIs.hpp" -#include "ingen/World.hpp" -#include "ingen/paths.hpp" -#include "raul/Array.hpp" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" +#include <ingen/Forge.hpp> +#include <ingen/Interface.hpp> +#include <ingen/Message.hpp> +#include <ingen/Node.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <ingen/URI.hpp> +#include <ingen/URIs.hpp> +#include <ingen/World.hpp> +#include <ingen/paths.hpp> +#include <raul/Array.hpp> +#include <raul/Path.hpp> #include <cassert> #include <cstddef> @@ -50,11 +50,7 @@ #include <string> #include <string_view> -namespace ingen::server { - -class RunContext; - -namespace events { +namespace ingen::server::events { Delete::Delete(Engine& engine, const std::shared_ptr<Interface>& client, @@ -104,7 +100,7 @@ Delete::pre_process(PreProcessContext& ctx) } // Take a writer lock while we modify the store - std::lock_guard<Store::Mutex> lock(_engine.store()->mutex()); + const std::lock_guard<Store::Mutex> lock{_engine.store()->mutex()}; _engine.store()->remove(iter, _removed_objects); @@ -113,14 +109,14 @@ Delete::pre_process(PreProcessContext& ctx) _disconnect_event = std::make_unique<DisconnectAll>(_engine, parent, _block.get()); _disconnect_event->pre_process(ctx); - _compiled_graph = ctx.maybe_compile(*_engine.maid(), *parent); + _compiled_graph = ctx.maybe_compile(*parent); } else if (_port) { parent->remove_port(*_port); _disconnect_event = std::make_unique<DisconnectAll>(_engine, parent, _port.get()); _disconnect_event->pre_process(ctx); - _compiled_graph = ctx.maybe_compile(*_engine.maid(), *parent); + _compiled_graph = ctx.maybe_compile(*parent); if (parent->enabled()) { _ports_array = parent->build_ports_array(*_engine.maid()); assert(_ports_array->size() == parent->num_ports_non_rt()); @@ -182,14 +178,14 @@ Delete::execute(RunContext& ctx) } if (parent && _compiled_graph) { - parent->set_compiled_graph(std::move(_compiled_graph)); + _compiled_graph = parent->swap_compiled_graph(std::move(_compiled_graph)); } } void Delete::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS && (_block || _port)) { if (_block) { _block->deactivate(); @@ -225,11 +221,10 @@ Delete::undo(Interface& target) if (c.first != _msg.uri.path()) { target.set_property(path_to_uri(c.first), uris.lv2_index, - forge.make(int32_t(c.second.first))); + forge.make(static_cast<int32_t>(c.second.first))); } } } } -} // namespace events -} // namespace ingen::server +} // namespace ingen::server::events diff --git a/src/server/events/Delete.hpp b/src/server/events/Delete.hpp index 840b8415..7e901f4b 100644 --- a/src/server/events/Delete.hpp +++ b/src/server/events/Delete.hpp @@ -17,16 +17,15 @@ #ifndef INGEN_EVENTS_DELETE_HPP #define INGEN_EVENTS_DELETE_HPP -#include "BlockImpl.hpp" #include "ControlBindings.hpp" #include "Event.hpp" #include "GraphImpl.hpp" #include "types.hpp" -#include "ingen/Message.hpp" -#include "ingen/Store.hpp" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" +#include <ingen/Message.hpp> +#include <ingen/Store.hpp> +#include <raul/Maid.hpp> +#include <raul/Path.hpp> #include <cstdint> #include <map> @@ -35,18 +34,19 @@ #include <utility> #include <vector> +// IWYU pragma: no_include <iterator> + namespace ingen { class Interface; namespace server { +class BlockImpl; class CompiledGraph; class DuplexPort; class Engine; class EnginePort; -class PreProcessContext; -class RunContext; namespace events { @@ -80,7 +80,7 @@ private: std::shared_ptr<DuplexPort> _port; ///< Non-null iff a port EnginePort* _engine_port{nullptr}; raul::managed_ptr<GraphImpl::Ports> _ports_array; ///< New (external) ports for Graph - raul::managed_ptr<CompiledGraph> _compiled_graph; ///< Graph's new process order + std::unique_ptr<CompiledGraph> _compiled_graph; ///< Graph's new process order std::unique_ptr<DisconnectAll> _disconnect_event; Store::Objects _removed_objects; IndexChanges _port_index_changes; diff --git a/src/server/events/Delta.cpp b/src/server/events/Delta.cpp index 0b8cab39..cba21214 100644 --- a/src/server/events/Delta.cpp +++ b/src/server/events/Delta.cpp @@ -32,23 +32,24 @@ #include "PortType.hpp" #include "SetPortValue.hpp" -#include "ingen/Atom.hpp" -#include "ingen/FilePath.hpp" -#include "ingen/Forge.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Log.hpp" -#include "ingen/Message.hpp" -#include "ingen/Node.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "ingen/URIs.hpp" -#include "ingen/World.hpp" -#include "ingen/paths.hpp" -#include "lilv/lilv.h" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" - -#include <algorithm> +#include <ingen/Atom.hpp> +#include <ingen/FilePath.hpp> +#include <ingen/Forge.hpp> +#include <ingen/Interface.hpp> +#include <ingen/Log.hpp> +#include <ingen/Message.hpp> +#include <ingen/Node.hpp> +#include <ingen/Properties.hpp> +#include <ingen/Resource.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <ingen/URI.hpp> +#include <ingen/URIs.hpp> +#include <ingen/World.hpp> +#include <ingen/paths.hpp> +#include <lilv/lilv.h> +#include <raul/Path.hpp> + #include <memory> #include <mutex> #include <set> @@ -57,11 +58,7 @@ #include <utility> #include <vector> -namespace ingen::server { - -class PreProcessContext; - -namespace events { +namespace ingen::server::events { Delta::Delta(Engine& engine, const std::shared_ptr<Interface>& client, @@ -213,7 +210,7 @@ Delta::pre_process(PreProcessContext& ctx) return Event::pre_process_done(Status::FAILURE); } - std::lock_guard<Store::Mutex> lock(_engine.store()->mutex()); + const std::lock_guard<Store::Mutex> lock{_engine.store()->mutex()}; _object = is_graph_object ? static_cast<ingen::Resource*>(_engine.store()->get(uri_to_path(_subject))) @@ -225,7 +222,7 @@ Delta::pre_process(PreProcessContext& ctx) } if (is_graph_object && !_object) { - raul::Path path(uri_to_path(_subject)); + const raul::Path path{uri_to_path(_subject)}; bool is_graph = false; bool is_block = false; @@ -318,8 +315,8 @@ Delta::pre_process(PreProcessContext& ctx) const Property& value = p.second; SpecialType op = SpecialType::NONE; if (obj) { - Resource& resource = *obj; if (value != uris.patch_wildcard) { + Resource& resource = *obj; if (resource.add_property(key, value, value.context())) { _added.emplace(key, value); } @@ -397,7 +394,7 @@ Delta::pre_process(PreProcessContext& ctx) op = SpecialType::ENABLE; // FIXME: defer until all other data has been processed if (value.get<int32_t>() && !_graph->enabled()) { - if (!(_compiled_graph = compile(*_engine.maid(), *_graph))) { + if (!(_compiled_graph = compile(*_graph))) { _status = Status::COMPILATION_FAILED; } } @@ -516,7 +513,7 @@ Delta::execute(RunContext& ctx) if (_graph) { if (value.get<int32_t>()) { if (_compiled_graph) { - _graph->set_compiled_graph(std::move(_compiled_graph)); + _compiled_graph = _graph->swap_compiled_graph(std::move(_compiled_graph)); } _graph->enable(); } else { @@ -594,7 +591,7 @@ Delta::post_process() _state.reset(); } - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (_create_event) { _create_event->post_process(); @@ -673,5 +670,4 @@ Delta::get_execution() const return _block ? Execution::ATOMIC : Execution::NORMAL; } -} // namespace events -} // namespace ingen::server +} // namespace ingen::server::events diff --git a/src/server/events/Delta.hpp b/src/server/events/Delta.hpp index 35357a26..befbdcc7 100644 --- a/src/server/events/Delta.hpp +++ b/src/server/events/Delta.hpp @@ -18,24 +18,22 @@ #define INGEN_EVENTS_DELTA_HPP #include "ClientUpdate.hpp" +#include "CompiledGraph.hpp" #include "ControlBindings.hpp" #include "Event.hpp" #include "SetPortValue.hpp" #include "State.hpp" #include "types.hpp" -#include "ingen/Properties.hpp" -#include "ingen/Resource.hpp" -#include "ingen/URI.hpp" -#include "raul/Maid.hpp" +#include <ingen/Properties.hpp> +#include <ingen/Resource.hpp> +#include <ingen/URI.hpp> #include <cstdint> #include <memory> #include <optional> #include <vector> -// IWYU pragma: no_include <algorithm> - namespace ingen { class Interface; @@ -45,11 +43,8 @@ struct SetProperty; namespace server { -class CompiledGraph; class Engine; class GraphImpl; -class PreProcessContext; -class RunContext; namespace events { @@ -117,7 +112,7 @@ private: ClientUpdate _update; ingen::Resource* _object{nullptr}; GraphImpl* _graph{nullptr}; - raul::managed_ptr<CompiledGraph> _compiled_graph; + std::unique_ptr<CompiledGraph> _compiled_graph; ControlBindings::Binding* _binding{nullptr}; StatePtr _state; Resource::Graph _context; diff --git a/src/server/events/Disconnect.cpp b/src/server/events/Disconnect.cpp index ef0cbd0b..7189fdd0 100644 --- a/src/server/events/Disconnect.cpp +++ b/src/server/events/Disconnect.cpp @@ -14,7 +14,7 @@ along with Ingen. If not, see <http://www.gnu.org/licenses/>. */ -#include "events/Disconnect.hpp" +#include "Disconnect.hpp" #include "BlockImpl.hpp" #include "Broadcaster.hpp" @@ -30,14 +30,15 @@ #include "PreProcessContext.hpp" #include "ThreadManager.hpp" -#include "ingen/Atom.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Node.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "raul/Array.hpp" -#include "raul/Maid.hpp" -#include "raul/Path.hpp" +#include <ingen/Atom.hpp> +#include <ingen/Interface.hpp> +#include <ingen/Message.hpp> +#include <ingen/Node.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <raul/Array.hpp> +#include <raul/Maid.hpp> +#include <raul/Path.hpp> #include <cassert> #include <cstdint> @@ -117,7 +118,7 @@ Disconnect::Impl::Impl(Engine& e, bool Disconnect::pre_process(PreProcessContext& ctx) { - std::lock_guard<Store::Mutex> lock(_engine.store()->mutex()); + const std::lock_guard<Store::Mutex> lock{_engine.store()->mutex()}; if (_msg.tail.parent().parent() != _msg.head.parent().parent() && _msg.tail.parent() != _msg.head.parent().parent() @@ -168,10 +169,10 @@ Disconnect::pre_process(PreProcessContext& ctx) _impl = std::make_unique<Impl>(_engine, _graph, - dynamic_cast<PortImpl*>(tail), + tail, dynamic_cast<InputPort*>(head)); - _compiled_graph = ctx.maybe_compile(*_engine.maid(), *_graph); + _compiled_graph = ctx.maybe_compile(*_graph); return Event::pre_process_done(Status::SUCCESS); } @@ -208,7 +209,8 @@ Disconnect::execute(RunContext& ctx) if (_status == Status::SUCCESS) { if (_impl->execute(ctx, true)) { if (_compiled_graph) { - _graph->set_compiled_graph(std::move(_compiled_graph)); + _compiled_graph = + _graph->swap_compiled_graph(std::move(_compiled_graph)); } } else { _status = Status::NOT_FOUND; @@ -219,7 +221,7 @@ Disconnect::execute(RunContext& ctx) void Disconnect::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS) { _engine.broadcaster()->message(_msg); } diff --git a/src/server/events/Disconnect.hpp b/src/server/events/Disconnect.hpp index 71ad4204..92dd81d3 100644 --- a/src/server/events/Disconnect.hpp +++ b/src/server/events/Disconnect.hpp @@ -21,8 +21,8 @@ #include "PortImpl.hpp" #include "types.hpp" -#include "ingen/Message.hpp" -#include "raul/Maid.hpp" +#include <ingen/Message.hpp> +#include <raul/Maid.hpp> #include <memory> @@ -37,7 +37,6 @@ class CompiledGraph; class Engine; class GraphImpl; class InputPort; -class PreProcessContext; class RunContext; namespace events { @@ -83,7 +82,7 @@ private: const ingen::Disconnect _msg; GraphImpl* _graph{nullptr}; std::unique_ptr<Impl> _impl; - raul::managed_ptr<CompiledGraph> _compiled_graph; + std::unique_ptr<CompiledGraph> _compiled_graph; }; } // namespace events diff --git a/src/server/events/DisconnectAll.cpp b/src/server/events/DisconnectAll.cpp index 957c6a6f..8e7bfbbe 100644 --- a/src/server/events/DisconnectAll.cpp +++ b/src/server/events/DisconnectAll.cpp @@ -14,26 +14,29 @@ along with Ingen. If not, see <http://www.gnu.org/licenses/>. */ -#include "events/DisconnectAll.hpp" +#include "DisconnectAll.hpp" #include "ArcImpl.hpp" #include "BlockImpl.hpp" #include "Broadcaster.hpp" #include "CompiledGraph.hpp" +#include "Disconnect.hpp" #include "Engine.hpp" #include "GraphImpl.hpp" #include "InputPort.hpp" #include "NodeImpl.hpp" #include "PortImpl.hpp" #include "PreProcessContext.hpp" -#include "events/Disconnect.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Node.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "raul/Maid.hpp" +#include <ingen/Interface.hpp> +#include <ingen/Message.hpp> +#include <ingen/Node.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <raul/Path.hpp> +#include <algorithm> +#include <iterator> #include <memory> #include <mutex> #include <set> @@ -68,7 +71,7 @@ DisconnectAll::DisconnectAll(Engine& engine, DisconnectAll::~DisconnectAll() { - for (auto& i : _impls) { + for (auto* i : _impls) { delete i; } } @@ -109,28 +112,35 @@ DisconnectAll::pre_process(PreProcessContext& ctx) } // Create disconnect events to erase adjacent arcs in parent - for (const auto& a : adjacent_arcs(_parent)) { - _impls.push_back( - new Disconnect::Impl(_engine, - _parent, - dynamic_cast<PortImpl*>(a->tail()), - dynamic_cast<InputPort*>(a->head()))); - } + const auto& arcs = adjacent_arcs(_parent); + std::transform(arcs.begin(), + arcs.end(), + std::back_inserter(_impls), + [this](const auto& a) { + return new Disconnect::Impl(_engine, + _parent, + a->tail(), + dynamic_cast<InputPort*>(a->head())); + }); // Create disconnect events to erase adjacent arcs in parent's parent if (_port && _parent->parent()) { - auto* const parent_parent = dynamic_cast<GraphImpl*>(_parent->parent()); - for (const auto& a : adjacent_arcs(parent_parent)) { - _impls.push_back( - new Disconnect::Impl(_engine, - parent_parent, - dynamic_cast<PortImpl*>(a->tail()), - dynamic_cast<InputPort*>(a->head()))); - } + auto* const grandparent = dynamic_cast<GraphImpl*>(_parent->parent()); + const auto& parent_arcs = adjacent_arcs(grandparent); + + std::transform(parent_arcs.begin(), + parent_arcs.end(), + std::back_inserter(_impls), + [this, grandparent](const auto& a) { + return new Disconnect::Impl(_engine, + grandparent, + a->tail(), + dynamic_cast<InputPort*>(a->head())); + }); } if (!_deleting && ctx.must_compile(*_parent)) { - if (!(_compiled_graph = compile(*_engine.maid(), *_parent))) { + if (!(_compiled_graph = compile(*_parent))) { return Event::pre_process_done(Status::COMPILATION_FAILED); } } @@ -149,14 +159,14 @@ DisconnectAll::execute(RunContext& ctx) } if (_compiled_graph) { - _parent->set_compiled_graph(std::move(_compiled_graph)); + _compiled_graph = _parent->swap_compiled_graph(std::move(_compiled_graph)); } } void DisconnectAll::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS) { _engine.broadcaster()->message(_msg); } diff --git a/src/server/events/DisconnectAll.hpp b/src/server/events/DisconnectAll.hpp index 70da5dd6..0eeda6f8 100644 --- a/src/server/events/DisconnectAll.hpp +++ b/src/server/events/DisconnectAll.hpp @@ -21,8 +21,7 @@ #include "Event.hpp" #include "types.hpp" -#include "ingen/Message.hpp" -#include "raul/Maid.hpp" +#include <ingen/Message.hpp> #include <list> #include <memory> @@ -41,8 +40,6 @@ class CompiledGraph; class Engine; class GraphImpl; class PortImpl; -class PreProcessContext; -class RunContext; namespace events { @@ -79,7 +76,7 @@ private: BlockImpl* _block; PortImpl* _port; Impls _impls; - raul::managed_ptr<CompiledGraph> _compiled_graph; + std::unique_ptr<CompiledGraph> _compiled_graph; bool _deleting; }; diff --git a/src/server/events/Get.cpp b/src/server/events/Get.cpp index f4cbb49d..45e7ea94 100644 --- a/src/server/events/Get.cpp +++ b/src/server/events/Get.cpp @@ -22,20 +22,22 @@ #include "GraphImpl.hpp" #include "PortImpl.hpp" -#include "ingen/Forge.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Node.hpp" -#include "ingen/Properties.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "ingen/URI.hpp" -#include "ingen/URIs.hpp" -#include "ingen/World.hpp" -#include "ingen/paths.hpp" +#include <ingen/Forge.hpp> +#include <ingen/Interface.hpp> +#include <ingen/Message.hpp> +#include <ingen/Node.hpp> +#include <ingen/Properties.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <ingen/URI.hpp> +#include <ingen/URIs.hpp> +#include <ingen/World.hpp> +#include <ingen/paths.hpp> #include <cstdint> #include <memory> #include <mutex> +#include <utility> namespace ingen::server::events { @@ -50,7 +52,7 @@ Get::Get(Engine& engine, bool Get::pre_process(PreProcessContext&) { - std::lock_guard<Store::Mutex> lock(_engine.store()->mutex()); + const std::lock_guard<Store::Mutex> lock{_engine.store()->mutex()}; const auto& uri = _msg.subject; if (uri == "ingen:/plugins") { @@ -96,7 +98,7 @@ Get::execute(RunContext&) void Get::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS && _request_client) { if (_msg.subject == "ingen:/plugins") { _engine.broadcaster()->send_plugins_to(_request_client.get(), _plugins); @@ -105,11 +107,11 @@ Get::post_process() URIs& uris = _engine.world().uris(); Properties props = { { uris.param_sampleRate, - uris.forge.make(int32_t(_engine.sample_rate())) }, + uris.forge.make(static_cast<int32_t>(_engine.sample_rate())) }, { uris.bufsz_maxBlockLength, - uris.forge.make(int32_t(_engine.block_length())) }, + uris.forge.make(static_cast<int32_t>(_engine.block_length())) }, { uris.ingen_numThreads, - uris.forge.make(int32_t(_engine.n_threads())) } }; + uris.forge.make(static_cast<int32_t>(_engine.n_threads())) } }; const Properties load_props = _engine.load_properties(); props.insert(load_props.begin(), load_props.end()); diff --git a/src/server/events/Get.hpp b/src/server/events/Get.hpp index 1ec49bfa..0f5ed235 100644 --- a/src/server/events/Get.hpp +++ b/src/server/events/Get.hpp @@ -17,7 +17,7 @@ #ifndef INGEN_EVENTS_GET_HPP #define INGEN_EVENTS_GET_HPP -#include "ingen/Message.hpp" +#include <ingen/Message.hpp> #include "BlockFactory.hpp" #include "ClientUpdate.hpp" @@ -35,8 +35,6 @@ namespace server { class Engine; class PluginImpl; -class PreProcessContext; -class RunContext; namespace events { diff --git a/src/server/events/Mark.cpp b/src/server/events/Mark.cpp index 97acdbbb..b60b0432 100644 --- a/src/server/events/Mark.cpp +++ b/src/server/events/Mark.cpp @@ -14,10 +14,7 @@ along with Ingen. If not, see <http://www.gnu.org/licenses/>. */ -#include "events/Mark.hpp" - -#include "ingen/Message.hpp" -#include "ingen/Status.hpp" +#include "Mark.hpp" #include "CompiledGraph.hpp" #include "Engine.hpp" @@ -25,6 +22,9 @@ #include "PreProcessContext.hpp" #include "UndoStack.hpp" +#include <ingen/Message.hpp> +#include <ingen/Status.hpp> + #include <cassert> #include <memory> #include <unordered_set> @@ -84,7 +84,7 @@ Mark::pre_process(PreProcessContext& ctx) ctx.set_in_bundle(false); if (!ctx.dirty_graphs().empty()) { for (GraphImpl* g : ctx.dirty_graphs()) { - auto cg = compile(*_engine.maid(), *g); + auto cg = compile(*g); if (cg) { _compiled_graphs.emplace(g, std::move(cg)); } @@ -101,7 +101,7 @@ void Mark::execute(RunContext&) { for (auto& g : _compiled_graphs) { - g.first->set_compiled_graph(std::move(g.second)); + g.second = g.first->swap_compiled_graph(std::move(g.second)); } } diff --git a/src/server/events/Mark.hpp b/src/server/events/Mark.hpp index ea130eda..e7180764 100644 --- a/src/server/events/Mark.hpp +++ b/src/server/events/Mark.hpp @@ -17,13 +17,10 @@ #ifndef INGEN_EVENTS_MARK_HPP #define INGEN_EVENTS_MARK_HPP +#include "CompiledGraph.hpp" #include "Event.hpp" #include "types.hpp" -// IWYU pragma: no_include "CompiledGraph.hpp" - -#include "raul/Maid.hpp" - #include <map> #include <memory> @@ -35,11 +32,8 @@ struct BundleEnd; namespace server { -class CompiledGraph; // IWYU pragma: keep class Engine; class GraphImpl; -class PreProcessContext; -class RunContext; namespace events { @@ -75,8 +69,7 @@ public: private: enum class Type { BUNDLE_BEGIN, BUNDLE_END }; - using CompiledGraphs = - std::map<GraphImpl*, raul::managed_ptr<CompiledGraph>>; + using CompiledGraphs = std::map<GraphImpl*, std::unique_ptr<CompiledGraph>>; CompiledGraphs _compiled_graphs; Type _type; diff --git a/src/server/events/Move.cpp b/src/server/events/Move.cpp index ea05d34c..80ae5a11 100644 --- a/src/server/events/Move.cpp +++ b/src/server/events/Move.cpp @@ -14,16 +14,17 @@ along with Ingen. If not, see <http://www.gnu.org/licenses/>. */ -#include "events/Move.hpp" +#include "Move.hpp" #include "Broadcaster.hpp" #include "Driver.hpp" #include "Engine.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Status.hpp" -#include "ingen/Store.hpp" -#include "raul/Path.hpp" +#include <ingen/Interface.hpp> +#include <ingen/Message.hpp> +#include <ingen/Status.hpp> +#include <ingen/Store.hpp> +#include <raul/Path.hpp> #include <map> #include <memory> @@ -46,7 +47,7 @@ Move::Move(Engine& engine, bool Move::pre_process(PreProcessContext&) { - std::lock_guard<Store::Mutex> lock(_engine.store()->mutex()); + const std::lock_guard<Store::Mutex> lock{_engine.store()->mutex()}; if (!_msg.old_path.parent().is_parent_of(_msg.new_path)) { return Event::pre_process_done(Status::PARENT_DIFFERS, _msg.new_path); @@ -78,7 +79,7 @@ Move::execute(RunContext&) void Move::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS) { _engine.broadcaster()->message(_msg); } diff --git a/src/server/events/Move.hpp b/src/server/events/Move.hpp index 3940e825..cca4d310 100644 --- a/src/server/events/Move.hpp +++ b/src/server/events/Move.hpp @@ -20,7 +20,7 @@ #include "Event.hpp" #include "types.hpp" -#include "ingen/Message.hpp" +#include <ingen/Message.hpp> #include <memory> @@ -31,8 +31,6 @@ class Interface; namespace server { class Engine; -class PreProcessContext; -class RunContext; namespace events { diff --git a/src/server/events/SetPortValue.cpp b/src/server/events/SetPortValue.cpp index 8b599354..ba6859dd 100644 --- a/src/server/events/SetPortValue.cpp +++ b/src/server/events/SetPortValue.cpp @@ -24,11 +24,12 @@ #include "PortImpl.hpp" #include "RunContext.hpp" -#include "ingen/Forge.hpp" -#include "ingen/Status.hpp" -#include "ingen/URIs.hpp" -#include "ingen/World.hpp" -#include "lv2/atom/atom.h" +#include <ingen/Atom.hpp> +#include <ingen/Forge.hpp> +#include <ingen/Status.hpp> +#include <ingen/URIs.hpp> +#include <ingen/World.hpp> +#include <lv2/atom/atom.h> #include <cassert> #include <memory> @@ -54,7 +55,7 @@ SetPortValue::SetPortValue(Engine& engine, bool SetPortValue::pre_process(PreProcessContext&) { - ingen::URIs& uris = _engine.world().uris(); + const ingen::URIs& uris = _engine.world().uris(); if (_port->is_output()) { return Event::pre_process_done(Status::DIRECTION_MISMATCH, _port->path()); } @@ -92,8 +93,8 @@ SetPortValue::apply(RunContext& ctx) return; } - ingen::URIs& uris = _engine.world().uris(); - Buffer* buf = _port->buffer(0).get(); + const ingen::URIs& uris = _engine.world().uris(); + Buffer* buf = _port->buffer(0).get(); if (_buffer) { if (_port->user_buffer(ctx)) { @@ -127,7 +128,7 @@ SetPortValue::apply(RunContext& ctx) void SetPortValue::post_process() { - Broadcaster::Transfer t(*_engine.broadcaster()); + const Broadcaster::Transfer t{*_engine.broadcaster()}; if (respond() == Status::SUCCESS && !_activity) { _engine.broadcaster()->set_property( _port->uri(), diff --git a/src/server/events/SetPortValue.hpp b/src/server/events/SetPortValue.hpp index 69d742b8..32a8b761 100644 --- a/src/server/events/SetPortValue.hpp +++ b/src/server/events/SetPortValue.hpp @@ -22,7 +22,7 @@ #include "Event.hpp" #include "types.hpp" -#include "ingen/Atom.hpp" +#include <ingen/Atom.hpp> #include <cstdint> #include <memory> @@ -35,7 +35,6 @@ namespace server { class Engine; class PortImpl; -class PreProcessContext; class RunContext; namespace events { diff --git a/src/server/events/Undo.cpp b/src/server/events/Undo.cpp index ea8c7d69..db7c1c86 100644 --- a/src/server/events/Undo.cpp +++ b/src/server/events/Undo.cpp @@ -19,11 +19,11 @@ #include "Engine.hpp" #include "EventWriter.hpp" -#include "ingen/AtomReader.hpp" -#include "ingen/Interface.hpp" -#include "ingen/Message.hpp" -#include "ingen/Status.hpp" -#include "lv2/atom/atom.h" +#include <ingen/AtomReader.hpp> +#include <ingen/Interface.hpp> +#include <ingen/Message.hpp> +#include <ingen/Status.hpp> +#include <lv2/atom/atom.h> #include <deque> #include <memory> diff --git a/src/server/events/Undo.hpp b/src/server/events/Undo.hpp index eb9cb70a..818dc754 100644 --- a/src/server/events/Undo.hpp +++ b/src/server/events/Undo.hpp @@ -32,8 +32,6 @@ struct Undo; namespace server { class Engine; -class PreProcessContext; -class RunContext; namespace events { |