如何使用水平翻转动画呈现模态视图(例如在导航控制器上按下视图控制器)? 我试过这个,但它不起作用
[UIView beginAnimations:@"animation" context:nil];
[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromLeft forView:self.view cache:NO];
[self presentModalViewController:detailsViewController animated:NO];
[UIView commitAnimations];
谢谢!
答案 0 :(得分:7)
这就是你所需要的:
detailsViewController.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal;
[self presentModalViewController:detailsViewController animated:YES];