You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 21, 2023. It is now read-only.
that takes edgePadding as an argument and applying it, it adjusts centerCoordinate of the map (on the video centerCoordinate is marked as green square). But there is inconsistency how user interaction (and programmatic camera updates) resets this adjustment. As you can see on the video pan gesture doesn't reset adjustment but pinch gesture do.
Also there is no way to check if current centerCoordinate is actually adjusted or not.
Steps to reproduce
Setup camera
call (on the video called on "setWithPadding" tap)
observe mapView.centerCoordinate (green square on the video, added as MGLPointAnnotation and position is updated in delegate regionDidChange method) it's adjusted according to passed edgePadding from step 2.
move map with pan gesture, observe that mapView.centerCoordinate remains adjusted
zoom map with pinch gesture, observe that mapView.centerCoordinate resets to the map center
Expected behavior
I'd expect consistent behavior, either reset adjustment after any map interaction or remain of adjustment after any map interaction(but it's not clear how to reset it then)
Actual behavior
mapView.centerCoordinate adjustment is reset by zoom gesture and not reset by pan gesture
Thank you for bringing this issue to our attention and please excuse the delayed response. The Maps SDK team has been laser focused on our Maps SDK v10 RC release.
Good news: v10 supports the behavior you're looking for (gestures do not automatically reset padding). Unfortunately, after debating within our team we are unlikely to bring this capability to the legacy SDK. The primary reason for this is the possibility of breaking other customers' existing implementations. But it's also true that, although the legacy SDK will continue to receive critical bugfixes, we believe v10 is the future of our mobile offerings, and we must prioritize issues accordingly.
Please continue to share your needs with us, here or otherwise. We're eager to fix acute pain points and ensure that our future roadmap meets your requirements.
MGLMapView interface contains a method
that takes edgePadding as an argument and applying it, it adjusts
centerCoordinate
of the map (on the videocenterCoordinate
is marked as green square). But there is inconsistency how user interaction (and programmatic camera updates) resets this adjustment. As you can see on the video pan gesture doesn't reset adjustment but pinch gesture do.Also there is no way to check if current
centerCoordinate
is actually adjusted or not.Steps to reproduce
mapView.centerCoordinate
(green square on the video, added as MGLPointAnnotation and position is updated in delegateregionDidChange
method) it's adjusted according to passededgePadding
from step 2.mapView.centerCoordinate
remains adjustedmapView.centerCoordinate
resets to the map centerExpected behavior
I'd expect consistent behavior, either reset adjustment after any map interaction or remain of adjustment after any map interaction(but it's not clear how to reset it then)
Actual behavior
mapView.centerCoordinate
adjustment is reset by zoom gesture and not reset by pan gestureConfiguration
Mapbox SDK versions: 6.3.0, 5.6.1
iOS/macOS versions: 14.4
Device/simulator models: simulator iPhone 8
Xcode version: 12.4
The text was updated successfully, but these errors were encountered: