AppDelegate *appDelegate = (AppDelegate *)[[UIApplication sharedApplication] delegate]
NSMutableArray *allViewControllers = [NSMutableArray arrayWithArray:[appDelegate.navigationController viewControllers]];
for (UIViewController *aViewController in allViewControllers) {
if ([aViewController isKindOfClass:[RequiredViewController class]]) {
[self.navigationController popToViewController:aViewController animated:NO];
}
}
2014年4月11日 星期五
pop到某一個特定的view
2014年3月29日 星期六
自定義NavigationBar的Back鍵文字
UIBarButtonItem *backItem = [[UIBarButtonItem alloc] initWithTitle:@"" style:UIBarButtonItemStyleBordered target:nil action:nil];
[self.navigationItem setBackBarButtonItem:backItem];
[self.navigationController pushViewController:detailViewController animated:YES];
訂閱:
文章 (Atom)