mapbox / mapbox-gl-native

Interactive, thoroughly customizable maps in native Android, iOS, macOS, Node.js, and Qt applications, powered by vector tiles and OpenGL
https://mapbox.com/mobile
Other
4.35k stars 1.33k forks source link

[iOS] - MapView update center (and frame) of MGLAnnotationView on redraw #16495

Open emelyanovkirill opened 4 years ago

emelyanovkirill commented 4 years ago

Steps to reproduce

  1. Add MGLAnnotationView in mapView(_ mapView: MGLMapView, viewFor annotation: MGLAnnotation) -> MGLAnnotationView? method
  2. Change bound's size and center of MGLAnnotationView in func mapViewDidBecomeIdle(_ mapView: MGLMapView) method
  3. As a result, size remains unchanged, but MGLAnnotationView jumping between default frame location and mine several times per second

Expected behavior

Bounds of MGLAnnotationView depend on my bounds in func mapViewDidBecomeIdle(_ mapView: MGLMapView) method

Configuration

Mapbox SDK versions: pod Mapbox-iOS-SDK (5.9.0) iOS version: 13.5 Xcode version: 11.5