- (IBAction)showSecondViewController:(id)sender;
{
if (self.secondController==nil) {
self.secondController=[[SecondViewController alloc] initWithNibName:@"SecondViewController" bundle:nil];
}
// [self.view addSubview:self.secondController.view];
[UIView transitionWithView:self.view duration:0.5 options:UIViewAnimationOptionTransitionFlipFromRight |
UIViewAnimationOptionLayoutSubviews |UIViewAnimationOptionAllowAnimatedContent
animations:^{
[self.view addSubview:self.secondController.view];
} completion:^(BOOL finished) {
}];
}
Adding Animation between two views
最新推荐文章于 2021-12-03 01:00:00 发布