美文网首页
iOS中跨页面Pop控制器的方法

iOS中跨页面Pop控制器的方法

作者: AnthonyChen | 来源:发表于2017-03-26 21:41 被阅读41次

//便历导航栏内的所有控制

for(UIViewController *controller in self.navigationController.viewControllers) {

//判断是不是你想要pop的控制器

if([controller isKindOfClass:[OverWorkRecevice class]]){

//获取到控制器

OverWorkRecevice *owr = (OverWorkRecevice *)controller;

//pop回控制器

[self.navigationController popToViewController:owr animated:YES];

}

}

相关文章

网友评论

      本文标题:iOS中跨页面Pop控制器的方法

      本文链接:https://www.haomeiwen.com/subject/xttlottx.html