copyWith method
Copy the marker with new properties.
Implementation
CanvasMarker copyWith({
coord.LatLng? position,
CanvasPainter? painter,
HitArea? hitArea,
bool? rotate,
Function? onTap,
Function? onDoubleTap,
Function? onLongPress,
Function(bool)? onHover,
}) {
return CanvasMarker(
position: position ?? this.position,
painter: painter ?? this.painter,
hitArea: hitArea ?? this.hitArea,
rotate: rotate ?? this.rotate,
onTap: onTap ?? this.onTap,
);
}