skipAnimation method

void skipAnimation({
  1. bool jumpToDestination = true,
})

Terminates the current map animation.

Immediately stops any ongoing animated transition triggered by centering methods (centerOnCoordinates, centerOnArea, etc.) with animation enabled. By default, the map instantly completes the animation, jumping to the target destination. Set jumpToDestination to false to stop at the current intermediate position instead.

Use isAnimationInProgress to check if an animation is active before calling this method.

Parameters

  • jumpToDestination: If true, completes the animation instantly by jumping to the target. If false, stops at the current position. Defaults to true

See also:

Implementation

void skipAnimation({final bool jumpToDestination = true}) {
  objectMethod(
    _pointerId,
    'MapView',
    'skipAnimation',
    args: jumpToDestination,
  );
}