Extra instance of CLLocationManager?
I am working on a project where I create 2 instances of CLLocationManager, my question is that when I look in instrument whilst my code is running is shows 3 instances, is this right, what is creating the 3rd one, or is it just a system thing?
XCODE:
开发者_如何学运维INSTRUMENTS:
I suspect the middle one is being created by your MKMapView (I assume you are using one). MKMapView has a location manager behind it, it's how it can carry out the showUserLocation
feature. MKLocationManager
is not a public class, and the map view won't expose it to you so there's not much you can really do about it.
精彩评论