美文网首页iOS进阶之路
连续跳转界面的方法

连续跳转界面的方法

作者: 郑军红 | 来源:发表于2016-10-30 18:16 被阅读3次

    UIViewController*target =nil;

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

    {//遍历

    if([controllerisKindOfClass:[SecretGardenControllerclass]])

    {//这里判断是否为你想要跳转的页面

    target = controller;

    }

    }

    if(target) {

    [self.navigationControllerpopToViewController:targetanimated:YES];//跳转

    }

    相关文章

      网友评论

        本文标题:连续跳转界面的方法

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