我正在使用以下代码,它在地图视图上仅显示一个图钉(注释)。请帮我找出我的错误。
- (void)mapView:(MKMapView *)mapView didAddAnnotationViews:(NSArray *)views
{
//Here
NSLog(@"didAddAnnotationViews");
[self.mapView selectAnnotation:[[self.mapView annotations] objectAtIndex:0] animated:NO];
[self.mapView selectAnnotation:[[self.mapView annotations] objectAtIndex:1] animated:NO];
[self.mapView selectAnnotation:[[self.mapView annotations] objectAtIndex:2] animated:NO];
[self.mapView selectAnnotation:[[self.mapView annotations] objectAtIndex:3] animated:NO];
}
为什么只有一个视图引脚注释显示?