summaryrefslogtreecommitdiffstats
path: root/src/gui/GraphCanvas.hpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2013-01-12 23:38:03 +0000
committerDavid Robillard <d@drobilla.net>2013-01-12 23:38:03 +0000
commitdf1447c665e6c3631961297a9d3e9aff4e94c47f (patch)
treec0ff117c362e6d571f430f886ab62f372b59af08 /src/gui/GraphCanvas.hpp
parentbb335dca695273622b7a4ebbefbe9e089edb9ab4 (diff)
downloadingen-df1447c665e6c3631961297a9d3e9aff4e94c47f.tar.gz
ingen-df1447c665e6c3631961297a9d3e9aff4e94c47f.tar.bz2
ingen-df1447c665e6c3631961297a9d3e9aff4e94c47f.zip
Remove Raul::SharedPtr and switch to std::shared_ptr.
Use project local short type aliases for shared_ptr and friends. Move Raul::Disposable and Raul::Manageable into Raul::Maid. Use sets to store machina nodes and edges to avoid O(n) searches. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4939 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/gui/GraphCanvas.hpp')
-rw-r--r--src/gui/GraphCanvas.hpp38
1 files changed, 19 insertions, 19 deletions
diff --git a/src/gui/GraphCanvas.hpp b/src/gui/GraphCanvas.hpp
index 6d4bbc87..77498748 100644
--- a/src/gui/GraphCanvas.hpp
+++ b/src/gui/GraphCanvas.hpp
@@ -27,12 +27,12 @@
#include "ganv/Canvas.hpp"
#include "ganv/Module.hpp"
-#include "raul/SharedPtr.hpp"
+#include "ingen/Node.hpp"
+#include "ingen/client/ArcModel.hpp"
+#include "ingen/types.hpp"
#include "raul/Path.hpp"
#include "NodeModule.hpp"
-#include "ingen/Node.hpp"
-#include "ingen/client/ArcModel.hpp"
namespace Ingen {
@@ -49,10 +49,10 @@ class NodeModule;
class GraphCanvas : public Ganv::Canvas
{
public:
- GraphCanvas(App& app,
- SharedPtr<const Client::GraphModel> graph,
- int width,
- int height);
+ GraphCanvas(App& app,
+ SPtr<const Client::GraphModel> graph,
+ int width,
+ int height);
virtual ~GraphCanvas() {}
@@ -63,13 +63,13 @@ public:
void show_port_names(bool show);
bool show_port_names() const { return _show_port_names; }
- void add_plugin(SharedPtr<Client::PluginModel> pm);
- void add_block(SharedPtr<const Client::BlockModel> bm);
- void remove_block(SharedPtr<const Client::BlockModel> bm);
- void add_port(SharedPtr<const Client::PortModel> pm);
- void remove_port(SharedPtr<const Client::PortModel> pm);
- void connection(SharedPtr<const Client::ArcModel> am);
- void disconnection(SharedPtr<const Client::ArcModel> am);
+ void add_plugin(SPtr<Client::PluginModel> pm);
+ void add_block(SPtr<const Client::BlockModel> bm);
+ void remove_block(SPtr<const Client::BlockModel> bm);
+ void add_port(SPtr<const Client::PortModel> pm);
+ void remove_port(SPtr<const Client::PortModel> pm);
+ void connection(SPtr<const Client::ArcModel> am);
+ void disconnection(SPtr<const Client::ArcModel> am);
void get_new_module_location(double& x, double& y);
@@ -96,7 +96,7 @@ private:
void menu_new_graph();
void menu_load_graph();
void menu_properties();
- void load_plugin(WeakPtr<Client::PluginModel> plugin);
+ void load_plugin(WPtr<Client::PluginModel> plugin);
void build_menus();
@@ -116,7 +116,7 @@ private:
Node::Properties get_initial_data(Resource::Graph ctx=Resource::Graph::DEFAULT);
- Ganv::Port* get_port_view(SharedPtr<Client::PortModel> port);
+ Ganv::Port* get_port_view(SPtr<Client::PortModel> port);
void connect(Ganv::Node* src,
Ganv::Node* dst);
@@ -124,10 +124,10 @@ private:
void disconnect(Ganv::Node* src,
Ganv::Node* dst);
- App& _app;
- SharedPtr<const Client::GraphModel> _graph;
+ App& _app;
+ SPtr<const Client::GraphModel> _graph;
- typedef std::map<SharedPtr<const Client::ObjectModel>, Ganv::Module*> Views;
+ typedef std::map<SPtr<const Client::ObjectModel>, Ganv::Module*> Views;
Views _views;
int _auto_position_count;