在史蒂夫乔布斯今年早些时候发布iPhone SDK 4的主题演讲中,其中一张幻灯片显示"半卷曲页面过渡"是新SDK的一部分:
alt text http://cl.ly/c203189b44788d490ae8/content
我查看了iOS API文档,似乎无法找到这种转换.有谁知道它在哪里?
UIViewAnimationTransitionCurlUp然而,我有一个工作过渡使用,我希望动画中途停止,就像地图应用程序...有关如何实现这一点的任何想法?
我正在使用此代码用于页面卷曲效果....它在模拟器和设备中工作正常......但它不是(setType:@"pageCurl")苹果记录的api,这导致它被iPhone开发人员计划拒绝App Store审核流程:
animation = [CATransition animation];
[animation setDelegate:self];
[animation setDuration:1.0f];
animation.startProgress = 0.5;
animation.endProgress = 1;
[animation setTimingFunction:UIViewAnimationCurveEaseInOut];
[animation setType:@"pageCurl"];
[animation setSubtype:@"fromRight"];
[animation setRemovedOnCompletion:NO];
[animation setFillMode: @"extended"];
[animation setRemovedOnCompletion: NO];
[[imageView layer] addAnimation:animation
forKey:@"pageFlipAnimation"];
Run Code Online (Sandbox Code Playgroud)
所以我改变并使用这样的方式
[UIView beginAnimations:nil context:NULL];
[UIView setAnimationDuration:1];
[UIView setAnimationDelegate:self];
[UIView setAnimationBeginsFromCurrentState:YES];
[UIView setAnimationCurve:UIViewAnimationCurveLinear];
[UIView setAnimationWillStartSelector:@selector(transitionWillStart:finished:context:)];
[UIView setAnimationDidStopSelector:@selector(transitionDidStop:finished:context:)];
// other animation properties
[UIView setAnimationTransition:UIViewAnimationTransitionCurlUp
forView:imageView cache:YES];
// set view properties
[UIView commitAnimations];
Run Code Online (Sandbox Code Playgroud)
在上面的代码中,我想在中途停止页面卷曲效果..但我不能在中途停止它像ipod中的地图应用程序...这是否有任何修复?或是否有任何苹果记录的方法用于ipod touch中的页面卷曲效果?
我正在寻找很多.但没有得到任何答案?谁能帮我?在此先感谢..plz
有没有办法提出一个模态视图控制器,不包括UITabBarController的标签栏?
具体来说,我想使用UIModalTransitionStylePartialCurl,但保留底部栏,一个iPhone映射应用程序.
我需要在地图视图中实现半页卷曲,就像谷歌地图应用程序一样.我实施UIViewAnimationTransitionCurlUp,UIModalTransitionStylePartialCurl它不像谷歌地图那样完善.