转载来源:http://blog.csdn.net/ios_water/article/details/51283164
NSMutableArray *navigationArray = [[NSMutableArray alloc] initWithArray: self.navigationController.viewControllers];
// [navigationArray removeAllObjects]; // 移除所有的controller
[navigationArray removeObjectAtIndex: 2]; // 移除指定的controller
self.navigationController.viewControllers = navigationArray;
点击左上角的返回按钮时,就是你想要的结果了
|