MapKit取消selectAnnotation和Popover不会animation

我有一些自定义注释,当在标注附件控件上按下时,popup窗口显示更多信息(如从苹果的地图应用程序中)。

除了不animation,即使animation设置为YES,每件事情都是有效的。

码:

- (void)mapView:(MKMapView *)mapView annotationView:(MKAnnotationView *)view calloutAccessoryControlTapped:(UIControl *)control { [mapView deselectAnnotation:view.annotation animated:YES]; UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"MainStoryboard" bundle:nil]; _basePopupViewController = [storyboard instantiateViewControllerWithIdentifier:@"BasePopupViewController"]; _popover = [[UIPopoverController alloc] initWithContentViewController:_basePopupViewController]; [_popover presentPopoverFromRect:view.bounds inView:view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES]; }