how to pop when first pushed vc then presented modal vc 12 times?

前端 未结 6 890
被撕碎了的回忆
被撕碎了的回忆 2021-01-29 10:33

I have a navigation controller. I first pushed a VC, then presented 12 modals VC\'s. Now I want to pop to root viewController. How can I do that? Please help me out.

6条回答
  •  既然无缘
    2021-01-29 11:13

    Tell the pushed VC to dismissViewControllerAnimated:completion:. This will dismiss all the presented VCs. Now you can pop the pushed VC.

提交回复
热议问题