2011-02-23 118 views
2

如何用水平翻轉動畫呈現模態視圖(如在導航控制器上推視圖控制器)? 我試過這個但它不起作用模態的水平翻轉動畫UIView

[UIView beginAnimations:@"animation" context:nil]; 
[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromLeft forView:self.view cache:NO]; 
[self presentModalViewController:detailsViewController animated:NO]; 
[UIView commitAnimations]; 

謝謝!

回答

7

這就是你需要:

detailsViewController.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal; 
[self presentModalViewController:detailsViewController animated:YES];