美文网首页
Ios打开和结束控制器的两种方式

Ios打开和结束控制器的两种方式

作者: 宁静世界 | 来源:发表于2018-09-13 11:44 被阅读0次

    方式1

    打开
    self.navigationController?.pushViewController(vc, animated: true)

    退出
    self.navigationController?.popViewController(animated: true)

    方式二

    打开
    self.present(activityVC, animated: true, completion: { () -> Void in

        })
    

    退出
    self.dismiss(animated: false, completion: nil)

    相关文章

      网友评论

          本文标题:Ios打开和结束控制器的两种方式

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