Swift 3 - 实现简单的RootViewControlle

2017-03-02  本文已影响0人  Hero_Guo
var rootVC: RootViewController?

    func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
        // Override point for customization after application launch.
        
        self.window?.backgroundColor = UIColor.white
        self.window? = UIWindow(frame: UIScreen.main.bounds)
        self.window?.makeKeyAndVisible()
        
        self.rootVC = RootViewController()
        self.window?.rootViewController = self.rootVC
        
        return true
    }
上一篇下一篇

猜你喜欢

热点阅读