قالب وردپرس درنا توس
Home / IOS Development / swift – How can I change a showAnnotation zoom using iOS map box?

swift – How can I change a showAnnotation zoom using iOS map box?



I have a method (seen below) that zooms into a note that was dropped.

      func mapView (_ mapView: MGLMapView, didSelect annotation: MGLAnnotation) {
print ("Tappet")
mapView.showAnnotations (pointAnnotations, animated: true) // this makes the zooming
mapView.deselectAnnotation (annotation, animated: false)
}

This works, but I don't like the way it zooms. (At the moment it starts, as soon as you press, to zoom and then put something backwards, it starts centering the object until it comes to the right position. At which point it suddenly stops)
How can I change this to mimic the snapMaps zoom?

I think what's happening in their zoom is that the zoom begins a little after the centering begins, and all this happens much faster. In addition, the padding is not so sudden. I think it's as easy in things.


Source link