I'm trying to call the mapView(mapView: MKMapView, didDeselectAnnotationView view: MKAnnotationView)
function programmatically using this code:
dispatch_async(dispatch_get_main_queue()) {
for item in self.largeMapView.selectedAnnotations {
self.largeMapView.deselectAnnotation(item, animated: false)
}
}
but this doesn't do anything. If I press on the map, it is called, but I want it to be called without the need to press.