diff options
author | David Robillard <d@drobilla.net> | 2021-05-10 13:19:34 -0400 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2021-05-10 13:19:34 -0400 |
commit | c1d99e42674d26a2699e5a7244dbaa988820b40d (patch) | |
tree | 29a103fdb8536c6c6e42dcc8013f146fedcc8e14 /src/Canvas.hpp | |
parent | a280246c3043fc2ea1f50fa695539ac0bec44be1 (diff) | |
download | patchage-c1d99e42674d26a2699e5a7244dbaa988820b40d.tar.gz patchage-c1d99e42674d26a2699e5a7244dbaa988820b40d.tar.bz2 patchage-c1d99e42674d26a2699e5a7244dbaa988820b40d.zip |
Add Action representation to isolate behaviour from canvas objects
A step towards isolating the canvas and ultimately the entire UI away so it can
be replaced.
Diffstat (limited to 'src/Canvas.hpp')
-rw-r--r-- | src/Canvas.hpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/Canvas.hpp b/src/Canvas.hpp index c571c5e..3a15ca6 100644 --- a/src/Canvas.hpp +++ b/src/Canvas.hpp @@ -1,5 +1,5 @@ /* This file is part of Patchage. - * Copyright 2007-2020 David Robillard <d@drobilla.net> + * Copyright 2007-2021 David Robillard <d@drobilla.net> * * Patchage is free software: you can redistribute it and/or modify it under * the terms of the GNU General Public License as published by the Free @@ -17,6 +17,7 @@ #ifndef PATCHAGE_CANVAS_HPP #define PATCHAGE_CANVAS_HPP +#include "ActionSink.hpp" #include "ClientID.hpp" #include "PortID.hpp" #include "SignalDirection.hpp" @@ -39,15 +40,14 @@ namespace patchage { struct PortInfo; -class Patchage; class CanvasModule; class CanvasPort; -class Connector; +class Patchage; class Canvas : public Ganv::Canvas { public: - Canvas(Connector& connector, int width, int height); + Canvas(ActionSink& action_sink, int width, int height); CanvasPort* create_port(Patchage& patchage, const PortID& id, @@ -79,7 +79,7 @@ private: void on_connect(Ganv::Node* port1, Ganv::Node* port2); void on_disconnect(Ganv::Node* port1, Ganv::Node* port2); - Connector& _connector; + ActionSink& _action_sink; PortIndex _port_index; ModuleIndex _module_index; }; |