0
我想补充CATransition
到UIViewControllers
里面我是用NSTimer
CATransition动画添加到UIViewControllers
-(void)playAction:(id)sender
{
[audioPlayer play];
[self performSelector:@selector(displayviewsAction:) withObject:nil afterDelay:11.0];
}
- (void)displayviewsAction:(id)sender
{
First *firstController = [[First alloc] init];
firstController.view.frame = CGRectMake(0, 0, 320, 480);
[self.view addSubview:firstController.view];
[self.view addSubview:toolbar];
[firstController release];
self.timer = [NSTimer scheduledTimerWithTimeInterval:23 target:self selector:@selector(Second) userInfo:nil repeats:NO];
}
-(void)Second
{
Second *secondController = [[Second alloc] init];
secondController.view.frame = CGRectMake(0, 0, 320, 480);
[self.view addSubview:secondController.view];
[self.view addSubview:toolbar];
[secondController release];
self.timer = [NSTimer scheduledTimerWithTimeInterval:27 target:self selector:@selector(Third) userInfo:nil repeats:NO];
}
我如何添加CATransition
这些UIViewControllers
当他们从第一到第二等改变显示。
在此先感谢您的所有想法。
感谢您的帮助。真的很感激它。 – user1120133
我可以翻转catransition。 – user1120133
有几个动画类型存在,你可以检查这个更多细节 - https://developer.apple.com/library/mac/#documentation/graphicsimaging/reference/CATransition_class/Introduction/Introduction.html – rishi