OpsSUpdateDetails constructor

OpsSUpdateDetails(
  1. {Map<int, Offset> globalPointerLocations,
  2. Map<int, Offset> localPointerLocations,
  3. Offset focalPoint: Offset.zero,
  4. Offset localFocalPoint,
  5. double scale: 1.0,
  6. double horizontalScale: 1.0,
  7. double verticalScale: 1.0,
  8. double rotation: 0.0}
)

Creates details for GestureScaleUpdateCallback.

The focalPoint, scale, horizontalScale, verticalScale, rotation arguments must not be null. The scale, horizontalScale, and verticalScale argument must be greater than or equal to zero.

Implementation

OpsSUpdateDetails({
  this.globalPointerLocations,
  this.localPointerLocations,
  this.focalPoint = Offset.zero,
  Offset localFocalPoint,
  this.scale = 1.0,
  this.horizontalScale = 1.0,
  this.verticalScale = 1.0,
  this.rotation = 0.0,
})  : assert(focalPoint != null),
      assert(scale != null && scale >= 0.0),
      assert(horizontalScale != null && horizontalScale >= 0.0),
      assert(verticalScale != null && verticalScale >= 0.0),
      assert(rotation != null),
      localFocalPoint = localFocalPoint ?? focalPoint;