private void SelectNodesByRect(IGraphDrawerSystem graphDrawerSystem, Rect selection, Vector2 scroll) { selection.position -= scroll; var nodesUnderRect = graphDrawerSystem.GetNodeDrawInfoByRect(selection); graphDrawerSystem.Select(nodesUnderRect); }
private void TryCreateArc(IGraphDrawerSystem graphDrawerSystem, DrawingContext drawingContext) { var graphContext = GraphContext.Current; INodeDrawInfo nodeDrawInfo; if (graphDrawerSystem.GetNodeDrawInfoByPosition(drawingContext.GetMousePosition(), out nodeDrawInfo)) { var nodeTo = nodeDrawInfo; graphContext.AddArc(graphDrawerSystem.GetNode(_nodeFrom), graphDrawerSystem.GetNode(nodeTo)); } }