Reputation: 720
We are using the HereMaps SDK for iOS. We have route information being calculated in a table view for the user, and we are updating this information continuously to the database. We also have a map view that optionally shows the user his current position and updates the route and maneuvers continuously on the map. This is not crucial for the user experience so we have placed it in a toggle view mode. When they click on a map icon that view will be shown etc. but it is in the same class. This has worked fine for us for a few years. Lately, (and only with some particular iOS devices - iPhone SE 2nd generation and iPhone XR) we are experiencing freezing UI issues. We think that because the mapview is not in a controller of its own, but can be toggled to be shown or to be hidden,that this may be causing the freezes. Simply put, these devices do not enjoy rendering maps continuously to a hidden view. Is there a way to temporarily block or unblock just the updates to the map alone?
Upvotes: 0
Views: 166
Reputation: 720
I figured out how to fix this. The best way to keep the map from updating the UI, but still to keep using its other navigational back-end features is by setting or unsetting mapTracking to the Navigation Manager.
So in my toggle to show or hide map I did the following when showing the map:
navigationManager.mapTrackingEnabled = true
and the following when hiding it:
navigationManager.mapTrackingEnabled = false
Problem solved!
Upvotes: 1