From c22c440067195e9e0787604f8fb15c6f1f670329 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 17 Jul 2024 12:46:36 -0400 Subject: Clean up includes and forward declarations According to include-what-you-use 0.22 on LLVM 18, anyway. Most of the changes seem vaguely reasonable, so as usual, just go with what the tool says because it's most useful when reports are typically clean. --- src/Serialiser.cpp | 1 - src/SocketWriter.cpp | 1 + src/StreamWriter.cpp | 1 + src/client/GraphModel.cpp | 6 ++++++ src/gui/BreadCrumbs.cpp | 1 - src/gui/ConnectWindow.cpp | 1 - src/gui/GraphBox.cpp | 1 - src/gui/GraphCanvas.cpp | 1 - src/gui/GraphTreeWindow.cpp | 1 - src/gui/GraphView.cpp | 1 - src/gui/LoadGraphWindow.cpp | 1 - src/gui/LoadPluginWindow.cpp | 1 - src/gui/MessagesWindow.cpp | 1 - src/gui/NewSubgraphWindow.cpp | 1 - src/gui/NodeMenu.cpp | 1 - src/gui/NodeModule.cpp | 1 - src/gui/ObjectMenu.cpp | 1 - src/gui/Port.cpp | 1 - src/gui/PortMenu.cpp | 1 - src/gui/PropertiesWindow.cpp | 1 - src/gui/RenameWindow.cpp | 1 - src/gui/ThreadedLoader.cpp | 2 ++ src/gui/WindowFactory.cpp | 1 - src/server/BlockImpl.cpp | 1 - src/server/ClientUpdate.cpp | 1 + src/server/NodeImpl.cpp | 4 ++++ src/server/SocketListener.cpp | 1 + src/server/Task.hpp | 1 - src/server/UndoStack.hpp | 1 - src/server/events/CreateBlock.cpp | 1 - src/server/events/Delete.cpp | 1 - src/server/events/Delta.cpp | 1 - src/server/events/DisconnectAll.cpp | 1 + src/server/events/Get.cpp | 1 + 34 files changed, 18 insertions(+), 25 deletions(-) (limited to 'src') diff --git a/src/Serialiser.cpp b/src/Serialiser.cpp index 02f0c6e8..860334d6 100644 --- a/src/Serialiser.cpp +++ b/src/Serialiser.cpp @@ -28,7 +28,6 @@ #include "ingen/URIMap.hpp" #include "ingen/URIs.hpp" #include "ingen/World.hpp" -#include "ingen/runtime_paths.hpp" #include "lv2/core/lv2.h" #include "lv2/state/state.h" #include "lv2/ui/ui.h" diff --git a/src/SocketWriter.cpp b/src/SocketWriter.cpp index 0e35a761..47427e7f 100644 --- a/src/SocketWriter.cpp +++ b/src/SocketWriter.cpp @@ -16,6 +16,7 @@ #include "ingen/SocketWriter.hpp" +#include "ingen/URI.hpp" #include "raul/Socket.hpp" #include diff --git a/src/StreamWriter.cpp b/src/StreamWriter.cpp index f23a6205..0d3d97d6 100644 --- a/src/StreamWriter.cpp +++ b/src/StreamWriter.cpp @@ -17,6 +17,7 @@ #include "ingen/StreamWriter.hpp" #include "ingen/ColorContext.hpp" +#include "ingen/URI.hpp" namespace ingen { diff --git a/src/client/GraphModel.cpp b/src/client/GraphModel.cpp index 45d0eb31..1404f021 100644 --- a/src/client/GraphModel.cpp +++ b/src/client/GraphModel.cpp @@ -17,6 +17,7 @@ #include "ingen/client/GraphModel.hpp" #include "ingen/Atom.hpp" +#include "ingen/URI.hpp" #include "ingen/URIs.hpp" #include "ingen/client/ArcModel.hpp" #include "ingen/client/BlockModel.hpp" @@ -32,6 +33,11 @@ namespace ingen::client { +GraphModel::GraphModel(URIs& uris, const raul::Path& graph_path) + : BlockModel{uris, static_cast(uris.ingen_Graph), graph_path} +{ +} + void GraphModel::add_child(const std::shared_ptr& c) { diff --git a/src/gui/BreadCrumbs.cpp b/src/gui/BreadCrumbs.cpp index eb2d511b..be613407 100644 --- a/src/gui/BreadCrumbs.cpp +++ b/src/gui/BreadCrumbs.cpp @@ -23,7 +23,6 @@ #include "raul/Path.hpp" #include "raul/Symbol.hpp" -#include #include #include diff --git a/src/gui/ConnectWindow.cpp b/src/gui/ConnectWindow.cpp index f645bb30..b33c3b81 100644 --- a/src/gui/ConnectWindow.cpp +++ b/src/gui/ConnectWindow.cpp @@ -40,7 +40,6 @@ #include #include -#include #include #include #include diff --git a/src/gui/GraphBox.cpp b/src/gui/GraphBox.cpp index e4a95bed..0764e4ed 100644 --- a/src/gui/GraphBox.cpp +++ b/src/gui/GraphBox.cpp @@ -56,7 +56,6 @@ #include #include #include -#include #include #include #include diff --git a/src/gui/GraphCanvas.cpp b/src/gui/GraphCanvas.cpp index e02c4e5b..6d5c3b5a 100644 --- a/src/gui/GraphCanvas.cpp +++ b/src/gui/GraphCanvas.cpp @@ -67,7 +67,6 @@ #include #include #include -#include #include #include #include diff --git a/src/gui/GraphTreeWindow.cpp b/src/gui/GraphTreeWindow.cpp index fa3318bf..9c3c4b3d 100644 --- a/src/gui/GraphTreeWindow.cpp +++ b/src/gui/GraphTreeWindow.cpp @@ -32,7 +32,6 @@ #include "raul/Symbol.hpp" #include -#include #include #include #include diff --git a/src/gui/GraphView.cpp b/src/gui/GraphView.cpp index 7c01c3ae..5464b7c4 100644 --- a/src/gui/GraphView.cpp +++ b/src/gui/GraphView.cpp @@ -29,7 +29,6 @@ #include #include -#include #include #include #include diff --git a/src/gui/LoadGraphWindow.cpp b/src/gui/LoadGraphWindow.cpp index c9c18ae9..794cfe71 100644 --- a/src/gui/LoadGraphWindow.cpp +++ b/src/gui/LoadGraphWindow.cpp @@ -36,7 +36,6 @@ #include #include #include -#include #include #include #include diff --git a/src/gui/LoadPluginWindow.cpp b/src/gui/LoadPluginWindow.cpp index 6951f87a..c19baa87 100644 --- a/src/gui/LoadPluginWindow.cpp +++ b/src/gui/LoadPluginWindow.cpp @@ -34,7 +34,6 @@ #include #include #include -#include #include #include #include diff --git a/src/gui/MessagesWindow.cpp b/src/gui/MessagesWindow.cpp index 7f3e4b8c..62bcfd00 100644 --- a/src/gui/MessagesWindow.cpp +++ b/src/gui/MessagesWindow.cpp @@ -25,7 +25,6 @@ #include #include -#include #include #include #include diff --git a/src/gui/NewSubgraphWindow.cpp b/src/gui/NewSubgraphWindow.cpp index 28a5afa7..3f2fcecb 100644 --- a/src/gui/NewSubgraphWindow.cpp +++ b/src/gui/NewSubgraphWindow.cpp @@ -32,7 +32,6 @@ #include #include -#include #include #include #include diff --git a/src/gui/NodeMenu.cpp b/src/gui/NodeMenu.cpp index 83e88264..ced303fb 100644 --- a/src/gui/NodeMenu.cpp +++ b/src/gui/NodeMenu.cpp @@ -34,7 +34,6 @@ #include #include #include -#include #include #include #include diff --git a/src/gui/NodeModule.cpp b/src/gui/NodeModule.cpp index 1d9b4c9f..20cfdbb3 100644 --- a/src/gui/NodeModule.cpp +++ b/src/gui/NodeModule.cpp @@ -47,7 +47,6 @@ #include "raul/Symbol.hpp" #include -#include #include #include #include diff --git a/src/gui/ObjectMenu.cpp b/src/gui/ObjectMenu.cpp index f6966bd8..1e9e0e94 100644 --- a/src/gui/ObjectMenu.cpp +++ b/src/gui/ObjectMenu.cpp @@ -27,7 +27,6 @@ #include "ingen/client/ObjectModel.hpp" #include -#include #include #include #include diff --git a/src/gui/Port.cpp b/src/gui/Port.cpp index 3925ed0c..ecba0ac7 100644 --- a/src/gui/Port.cpp +++ b/src/gui/Port.cpp @@ -46,7 +46,6 @@ #include "raul/Symbol.hpp" #include "sord/sordmm.hpp" -#include #include #include #include diff --git a/src/gui/PortMenu.cpp b/src/gui/PortMenu.cpp index 95ba88dc..6cd30066 100644 --- a/src/gui/PortMenu.cpp +++ b/src/gui/PortMenu.cpp @@ -35,7 +35,6 @@ #include "raul/Symbol.hpp" #include -#include #include #include #include diff --git a/src/gui/PropertiesWindow.cpp b/src/gui/PropertiesWindow.cpp index 958a73c9..91473c1a 100644 --- a/src/gui/PropertiesWindow.cpp +++ b/src/gui/PropertiesWindow.cpp @@ -36,7 +36,6 @@ #include #include -#include #include #include #include diff --git a/src/gui/RenameWindow.cpp b/src/gui/RenameWindow.cpp index 66d8e918..0b6bdae9 100644 --- a/src/gui/RenameWindow.cpp +++ b/src/gui/RenameWindow.cpp @@ -31,7 +31,6 @@ #include #include -#include #include #include #include diff --git a/src/gui/ThreadedLoader.cpp b/src/gui/ThreadedLoader.cpp index 4cd382a0..170b9a0e 100644 --- a/src/gui/ThreadedLoader.cpp +++ b/src/gui/ThreadedLoader.cpp @@ -20,12 +20,14 @@ #include "ingen/Log.hpp" #include "ingen/Parser.hpp" +#include "ingen/Properties.hpp" #include "ingen/Serialiser.hpp" #include "ingen/URI.hpp" #include "ingen/World.hpp" #include "ingen/client/GraphModel.hpp" #include "raul/Path.hpp" #include "raul/Semaphore.hpp" +#include "raul/Symbol.hpp" #include #include diff --git a/src/gui/WindowFactory.cpp b/src/gui/WindowFactory.cpp index 010ef704..4fce885c 100644 --- a/src/gui/WindowFactory.cpp +++ b/src/gui/WindowFactory.cpp @@ -33,7 +33,6 @@ #include "raul/Path.hpp" #include -#include #include #include diff --git a/src/server/BlockImpl.cpp b/src/server/BlockImpl.cpp index d4285832..cae6b252 100644 --- a/src/server/BlockImpl.cpp +++ b/src/server/BlockImpl.cpp @@ -25,7 +25,6 @@ #include "lv2/urid/urid.h" #include "raul/Array.hpp" -#include "raul/Maid.hpp" #include "raul/Symbol.hpp" #include diff --git a/src/server/ClientUpdate.cpp b/src/server/ClientUpdate.cpp index c69f5b49..167cd294 100644 --- a/src/server/ClientUpdate.cpp +++ b/src/server/ClientUpdate.cpp @@ -27,6 +27,7 @@ #include "ingen/Forge.hpp" #include "ingen/Interface.hpp" #include "ingen/URIs.hpp" +#include "raul/Path.hpp" #include diff --git a/src/server/NodeImpl.cpp b/src/server/NodeImpl.cpp index c76c66d4..f771d953 100644 --- a/src/server/NodeImpl.cpp +++ b/src/server/NodeImpl.cpp @@ -27,6 +27,10 @@ #include #include +namespace raul { +class Symbol; +} + namespace ingen::server { NodeImpl::NodeImpl(const ingen::URIs& uris, diff --git a/src/server/SocketListener.cpp b/src/server/SocketListener.cpp index 075d78cc..a3139660 100644 --- a/src/server/SocketListener.cpp +++ b/src/server/SocketListener.cpp @@ -28,6 +28,7 @@ #include #include +#include #include #include diff --git a/src/server/Task.hpp b/src/server/Task.hpp index 30941f28..c665c16f 100644 --- a/src/server/Task.hpp +++ b/src/server/Task.hpp @@ -17,7 +17,6 @@ #ifndef INGEN_ENGINE_TASK_HPP #define INGEN_ENGINE_TASK_HPP -#include #include #include #include diff --git a/src/server/UndoStack.hpp b/src/server/UndoStack.hpp index 8195920a..8954f05d 100644 --- a/src/server/UndoStack.hpp +++ b/src/server/UndoStack.hpp @@ -24,7 +24,6 @@ #include "server.h" #include "sratom/sratom.h" -#include #include #include #include diff --git a/src/server/events/CreateBlock.cpp b/src/server/events/CreateBlock.cpp index 0ad050f2..7f50411c 100644 --- a/src/server/events/CreateBlock.cpp +++ b/src/server/events/CreateBlock.cpp @@ -40,7 +40,6 @@ #include "ingen/URIs.hpp" #include "ingen/World.hpp" #include "ingen/paths.hpp" -#include "lilv/lilv.h" #include "raul/Path.hpp" #include "raul/Symbol.hpp" diff --git a/src/server/events/Delete.cpp b/src/server/events/Delete.cpp index bcebe2ba..b42f0652 100644 --- a/src/server/events/Delete.cpp +++ b/src/server/events/Delete.cpp @@ -40,7 +40,6 @@ #include "ingen/World.hpp" #include "ingen/paths.hpp" #include "raul/Array.hpp" -#include "raul/Maid.hpp" #include "raul/Path.hpp" #include diff --git a/src/server/events/Delta.cpp b/src/server/events/Delta.cpp index 11a0b0ff..3f9e3b9d 100644 --- a/src/server/events/Delta.cpp +++ b/src/server/events/Delta.cpp @@ -47,7 +47,6 @@ #include "lilv/lilv.h" #include "raul/Path.hpp" -#include #include #include #include diff --git a/src/server/events/DisconnectAll.cpp b/src/server/events/DisconnectAll.cpp index 87df61a5..e429e0e6 100644 --- a/src/server/events/DisconnectAll.cpp +++ b/src/server/events/DisconnectAll.cpp @@ -32,6 +32,7 @@ #include "ingen/Node.hpp" #include "ingen/Status.hpp" #include "ingen/Store.hpp" +#include "raul/Path.hpp" #include #include diff --git a/src/server/events/Get.cpp b/src/server/events/Get.cpp index 385e55f3..ab369c80 100644 --- a/src/server/events/Get.cpp +++ b/src/server/events/Get.cpp @@ -36,6 +36,7 @@ #include #include #include +#include namespace ingen::server::events { -- cgit v1.2.1