handleDoubleTap method

void handleDoubleTap({
  1. double? scale,
  2. Offset? doubleTapPosition,
})

Implementation

void handleDoubleTap({double? scale, Offset? doubleTapPosition}) {
  doubleTapPosition ??= _pointerDownPosition;
  scale ??= _gestureConfig!.initialScale;
  //scale = scale.clamp(_gestureConfig.minScale, _gestureConfig.maxScale);
  handleScaleStart(ScaleStartDetails(focalPoint: doubleTapPosition!));
  handleScaleUpdate(ScaleUpdateDetails(
    focalPoint: doubleTapPosition,
    scale: scale / _startingScale!,
    focalPointDelta: Offset.zero,
  ));
  if (scale < _gestureConfig!.minScale || scale > _gestureConfig!.maxScale) {
    handleScaleEnd(ScaleEndDetails());
  }
}