copyWith method

PanState copyWith({
  1. bool? isPanning,
  2. double? distance,
  3. bool? wasFlung,
})

Returns a copy of this PanState instance updated with the given values.

Implementation

PanState copyWith({
  bool? isPanning,
  double? distance,
  bool? wasFlung,
}) =>
    PanState(
      distance: distance ?? this.distance,
      isPanning: isPanning ?? this.isPanning,
      wasFlung: wasFlung ?? this.wasFlung,
    );