json is loading, but does nothing yet
This commit is contained in:
+12
-18
@@ -5,26 +5,20 @@
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
class GraphItem{
|
||||
namespace VISEQ::GRAPH {
|
||||
class GraphItem{
|
||||
|
||||
public:
|
||||
GraphItem() {static int _id; id=_id++;}
|
||||
std::vector<std::shared_ptr<GraphItem>> neighbors;
|
||||
int id = 0;
|
||||
GraphItemType graphItemType;
|
||||
public:
|
||||
GraphItem() {static int _id; id=_id++;}
|
||||
std::vector<std::shared_ptr<GraphItem>> neighbors;
|
||||
int id = 0;
|
||||
GraphItemType graphItemType;
|
||||
|
||||
virtual void draw(Vec2Df mouse, Camera2D cam) {};
|
||||
virtual GraphItemType getType() {return graphItemType;}
|
||||
virtual ~GraphItem() = default;
|
||||
virtual void draw(Vec2Df mouse, Camera2D cam) {};
|
||||
virtual GraphItemType getType() {return graphItemType;}
|
||||
virtual ~GraphItem() = default;
|
||||
|
||||
/*void to_json(json& j, const GraphItem& G){*/
|
||||
/* j = json{{"id",id},{"graphItemType",graphItemType},{"neighbors",neighbors}};*/
|
||||
/*}*/
|
||||
};
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/*typedef std::shared_ptr<GraphItem> SPTR_GraphItem;*/
|
||||
/*typedef std::vector<SPTR_GraphItem> VEC_SPTR_GraphItem;*/
|
||||
|
||||
//NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(GraphItem, id, graphItemType, neighbors)
|
||||
|
||||
Reference in New Issue
Block a user