Ios 有没有办法摆脱带有故事板的短ViewController?
我的代码是Ios 有没有办法摆脱带有故事板的短ViewController?,ios,swift,uiviewcontroller,Ios,Swift,Uiviewcontroller,我的代码是 else if indexPath.row == 4 { FUser.logOutCurrentUser { (success) in if success { tableView.deselectRow(at: indexPath, animated: true) let vc = UIStoryboard.init(name: "Main",
else if indexPath.row == 4 {
FUser.logOutCurrentUser { (success) in
if success {
tableView.deselectRow(at: indexPath, animated: true)
let vc = UIStoryboard.init(name: "Main", bundle: nil).instantiateViewController(identifier: "welcome") as! Login_VC
self.present(vc, animated: true, completion: nil)
} else {
self.alertController(title: "Alert !", message: "Network error. Try again in sometime.", titleAction: "Ok")
}
} // end of fuser
} // end of else index 4
将UIViewcontroller的
modalPresentationStyle
从automatic
更改为fullscreen
看
你也可以看看这篇文章:
此线程的解决方案:
let vc = UIViewController()
vc.modalPresentationStyle = .fullScreen //or .overFullScreen for transparency
self.present(vc, animated: true, completion: nil)
您还可以在Xcode接口生成器中更改此属性