默认显示当前位置注释

我在mapkit中显示了当前位置注释(蓝点)。 点击蓝点后显示注释,当我启动视图时,如何默认显示注释? 丝毫敲击销钉。

- (void)mapView:(MKMapView *)mv didAddAnnotationViews:(NSArray *)views { for(MKAnnotationView *annotationView in views) { if(annotationView.annotation == mv.userLocation) { self.mapView.userLocation.title= @"Current"; self.mapView.userLocation.subtitle= @"Location"; MKCoordinateRegion region; MKCoordinateSpan span; span.latitudeDelta=0.002; span.longitudeDelta=0.002; CLLocationCoordinate2D location=mv.userLocation.coordinate; region.span=span; region.center=location; [mv setRegion:region animated:YES]; [mv regionThatFits:region]; } } } 

在那种情况下,selectAnnotation应该工作,不是吗? 只需在一小段时间后执行Selector。

….与以前相同的代码,但插入此:

  id annotation = annotationView.annotation; [self performSelector:@selector(selectUserLocation:) withObject:annotation afterDelay:0.1f]; } } } - (void)selectUserLocation:(id)annotation{ [self.mapView selectAnnotation:annotation animated:YES]; }