【发布时间】:2013-02-02 01:26:51
【问题描述】:
如何在 mapView 中显示带有底部动画翻转的选项?就像 iPhone 中的原始地图应用程序一样?像这样:
谢谢!!
【问题讨论】:
标签: iphone objective-c ios mkmapview
如何在 mapView 中显示带有底部动画翻转的选项?就像 iPhone 中的原始地图应用程序一样?像这样:
谢谢!!
【问题讨论】:
标签: iphone objective-c ios mkmapview
将底层视图呈现为模态控制器并使用过渡样式 - 部分卷曲。像这样:
controller.modalTransitionStyle = UIModalTransitionStylePartialCurl;
[self presentModalViewController:controller animated:YES];
更新: 在 iOS6 中你应该这样做:
SecondeViewController *nextView = [[SecondeViewController alloc] init];
nextView.modalTransitionStyle = UIModalTransitionStylePartialCurl;
[self presentViewController:nextView animated:YES completion:Nil];
【讨论】:
UIViewAnimationTransition transition = UIViewAnimationTransitionCurlUp;
UIViewAnimationCurve curve = UIViewAnimationCurveEaseInOut;
[UIView beginAnimations:@"anim" context:NULL];
[UIView setAnimationCurve:curve];
[UIView setAnimationTransition:transition forView:[self view] cache:YES];
[UIView setAnimationDuration:1.0f];
[UIView commitAnimations];
【讨论】: