swift纯代码启动

记录下在didFinishLaunchingWithOptions中:

self.window=UIWindow(frame:UIScreen.main.bounds)

self.window!.backgroundColor=UIColor.white

//设置root

letrootVC =MainViewController()

self.window!.rootViewController= rootVC

self.window!.makeKeyAndVisible()

你可能感兴趣的:(swift纯代码启动)