码迷,mamicode.com
首页 > 其他好文 > 详细

UINavigationController 导航控制器 常用总结

时间:2015-09-07 22:26:09      阅读:212      评论:0      收藏:0      [点我收藏+]

标签:

//导航控制器跳转到下一页

[self.navigationController pushViewController:second animated:YES];

 

    //返回上一页

    [self.navigationController popViewControllerAnimated:YES];

 

    //返回首页:popToRootViewControllerAnimated   除第一个页面外,其他的页面全部出栈

    [self.navigationController popToRootViewControllerAnimated:YES];

 

 

    //self.navigationController.viewControllers  找到push过去的页面,并放到数组里面

    NSArray *viewController = self.navigationController.viewControllers;

    

    [self.navigationController popToViewController:viewController[2] animated:YES];

UINavigationController 导航控制器 常用总结

标签:

原文地址:http://www.cnblogs.com/pangbin/p/4790031.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!