setAnimateToHandler method

void setAnimateToHandler(
  1. void handler(
    1. GraphViewport target, {
    2. Curve curve,
    3. Duration duration,
    })?
)

Sets the handler for viewport animations.

This handler is invoked by the animate* methods to trigger smooth viewport animations via the ViewportAnimationMixin in NodeFlowEditor.

Called by NodeFlowEditor during initialization.

Implementation

void setAnimateToHandler(
  void Function(GraphViewport target, {Duration duration, Curve curve})?
  handler,
) {
  _onAnimateToViewport = handler;
}