gpt4 book ai didi

iphone - 如何设置推送和弹出 View Controller 流程

转载 作者:行者123 更新时间:2023-12-01 19:16:40 24 4
gpt4 key购买 nike

在我的应用程序中,我想从右到左设置弹出 View Controller 。当推送 View Controller 从左到右流动时,很好。我试过这个 How to change the Push and Pop animations in a navigation based app但它可以通过我想要的过渡动画 View 工作,没有从右到左的动画弹出 View Controller ?请帮助解决

最佳答案

流行效果

ViewController *back = [[ViewController alloc]initWithNibName:@"ViewController" bundle:nil];
NSMutableArray *vcs = [NSMutableArray arrayWithArray:self.navigationController.viewControllers];
[vcs insertObject:back atIndex:[vcs count]-1];
[self.navigationController setViewControllers:vcs animated:NO];
[self.navigationController popViewControllerAnimated:YES];

关于iphone - 如何设置推送和弹出 View Controller 流程,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12871029/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com