阅读背景:

当警报被解除时,如何弹出RootViewController?

来源:互联网 
@IBAction func addButton(sender: AnyObject) {

    let alert = UIAlertController(title: "New Exercise Added", message: "\(name)", preferredStyle: UIAlertControllerStyle.Alert)
    alert.addAction(UIAlertAction(title: "Ok!!", style: UIAlertActionStyle.Default, handler: nil))

    self.presentViewController(alert, animated: true, completion: nil)

    self.navigationController?.popToRootViewControllerAnimated(true)
    self.dismissViewControllerAnimated(true, completion: {})
    }
@IBAction func addButton(sender: AnyObject) {




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: