Iphone sdk 3.0 uiview动画过去在iphonesdk2.2上工作,现在它不再';sdk3.0上的t

Iphone sdk 3.0 uiview动画过去在iphonesdk2.2上工作,现在它不再';sdk3.0上的t,iphone-sdk-3.0,animation,uiview,uinavigationcontroller,Iphone Sdk 3.0,Animation,Uiview,Uinavigationcontroller,在iphone OS 2.2上运行应用程序时,我有一个动画块工作得很好。现在我为iPhoneOS3.0编译了同样的代码,但它不起作用 UIViewAnimationTransition trans = UIViewAnimationTransitionFlipFromLeft; [UIView beginAnimations: nil context: NULL]; UIView *forview = [[self view] superview]; [UIView setAnimation

在iphone OS 2.2上运行应用程序时,我有一个动画块工作得很好。现在我为iPhoneOS3.0编译了同样的代码,但它不起作用

UIViewAnimationTransition  trans = UIViewAnimationTransitionFlipFromLeft;

[UIView beginAnimations: nil context: NULL];
UIView *forview = [[self view] superview];
[UIView setAnimationTransition: trans forView:forview  cache: YES];
[UIView setAnimationDuration:1.0];

[[self navigationController] popViewControllerAnimated:NO]; 

[UIView commitAnimations];
代码所做的是,它使用导航控制器更改最上面的视图,但使用翻转过渡,而不是内置的

关于sdk中可能有什么变化或者我做错了什么,有什么想法吗


谢谢

这不是对您问题的直接回答,但根据您这样做的原因,使用
presentModalViewController:animated:
UIModalTransitionStyleFlipHorizontal
modalTransitionStyle
可以达到您想要的效果。谢谢您的回答,但那不是我需要的。无论如何,我通过appDelegate访问视图而不是使用[[self view]superview]方法解决了这个问题。在这种情况下,您应该将您的修复作为问题的答案发布,并将其标记为已回答。