IOS基础:窗口切换的几种方法


1 controller切换
AboutViewController *aboutViewController = [[AboutViewController alloc]init];

[self.navigationController pushViewController:aboutViewController animated:YES]; //新视图压入到栈中

[AboutViewController release];


AboutViewController 返回按钮:
[self.navigationController popViewControllerAnimated:YES];//弹出后返回到原视图

2 从上向上滑出
NewProfileViewController *newProfileController =[[ewProfileViewController alloc]init];

[self.navigationController presentModalViewController:newProfileController animated:YES];

[newProfileController release];

 

NewProfileViewController取消按钮:
[self dismissModalViewControllerAnimated:YES];

 

3 弹出窗口

4 窗口翻转


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM