TemporaryConnection constructor
TemporaryConnection({})
Creates a temporary connection for drag-and-drop operations.
Parameters:
startPoint: The position where the drag started (port position)startNodeId: ID of the node containing the starting portstartPortId: ID of the starting portisStartFromOutput: Whether the drag started from an output portstartNodeBounds: Bounds of the starting node for node-aware routinginitialCurrentPoint: Initial pointer position (typically same asstartPoint)targetNodeId: Optional ID of the target node (set when hovering over a port)targetPortId: Optional ID of the target port (set when hovering over a port)targetNodeBounds: Optional bounds of the target node (set when hovering)
Implementation
TemporaryConnection({
required this.startPoint,
required this.startNodeId,
required this.startPortId,
required this.isStartFromOutput,
required this.startNodeBounds,
required Offset initialCurrentPoint,
String? targetNodeId,
String? targetPortId,
Rect? targetNodeBounds,
}) : _currentPoint = Observable(initialCurrentPoint),
_targetNodeId = Observable(targetNodeId),
_targetPortId = Observable(targetPortId),
_targetNodeBounds = Observable(targetNodeBounds);