iOS 界面多次present后,dismiss到指定的界面方法

- (void)backAction:(UIButton *)sender{
    UIViewController *vc =self.presentingViewController;

 //ReadBookController要跳转的界面

    while (![vc isKindOfClass:[ReadBookController class]]) {
          vc = vc.presentingViewController;
    }
   [vc dismissViewControllerAnimated:YES completion:nil];
}

你可能感兴趣的:(iOS 界面多次present后,dismiss到指定的界面方法)