public virtual void AddEdge(RGEdge edge, string parent) { allEdges.Add(edge); var graph = GetGraphBox(parent); if (graph == null) { graph = new GraphBox(parent); graphBoxs.Add(graph); } //graph.AddEdge(edge); }
public RGEdge CreateEdge(LinkInfo info, Transform box, string centre) { RGEdge item = GetEdge(info.UID); if (item == null) { var from = GetNode(info.from.UID); var to = GetNode(info.to.UID); if (from != null && to != null) { var view = ZAssetController.Instance.ActivateAsset <GEdgeParts>(box); item = new RGEdge(); item.UpdateInfo(info, view, from, to); item.DrawLine(); item.Show(); AddEdge(item, centre); } } else { item.Show(); } return(item); }
public override void AddEdge(RGEdge edge, string parent) { allEdges.Add(edge); }