Quote:
Originally Posted by PhilSimpson
Beta 2 seems to have broken pinColors. Mine all appear red now. I noticed that the span issue I was having was listed as being fixed in beta 2, but I'm still getting zooming out when using setRegion.
Anyone?
|
I'm replying to Phils comment because I think this code is potentially an answer to why all pins might appear red. I have the following code in my app, and it works. But can anyone tell me why it doesn't result in an infinite loop?
Code:
- (MKAnnotationView *)mapView:(MKMapView *)passedMapView viewForAnnotation:(id <MKAnnotation>)annotation {
MKAnnotationView *annotationView;
if ([annotation class] == [MKUserLocation class] ) {
NSLog(@"Detected UserLocationAnnotation");
annotationView = [passedMapView viewForAnnotation:annotation];
[self doSomeStuffHere];
} else {
// Do other stuff for custom Annotation
}
return annotationView;
}