From ee9352958f1d3d4e4d3ee610d5c34f0579e708e3 Mon Sep 17 00:00:00 2001 From: gradient Date: Fri, 20 Oct 2017 18:51:10 -0500 Subject: [PATCH] node_editor.h: set up edgeList, emplace some test data --- src/gui/node_editor.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/gui/node_editor.h b/src/gui/node_editor.h index bde4b0f..921ea05 100644 --- a/src/gui/node_editor.h +++ b/src/gui/node_editor.h @@ -64,8 +64,10 @@ public: class NodeEditor { public: NodeEditor() { - nodeList.emplace_back("hi", Rect(10, 10, 60, 60)); - nodeList.emplace_back("hi2", Rect(10, 80, 60, 60)); + nodeList.emplace_back("hi", Rect(10, 10, 60, 60), 3, 1); + nodeList.emplace_back("hi2", Rect(80, 10, 60, 60), 1, 1); + + edgeList.emplace_back(&nodeList[0], &nodeList[1], 0, 0); } void draw_window(const char *title, bool *opened) { @@ -144,6 +146,7 @@ public: private: std::vector nodeList; + std::vector edgeList; ImVec2 scrolling = ImVec2(0.0f, 0.0f); bool show_grid = true;