Skip to content

Instantly share code, notes, and snippets.

@glennposadas
Last active May 29, 2016 03:11
Show Gist options
  • Save glennposadas/bd7bab55e15003a22bff05525f5532d8 to your computer and use it in GitHub Desktop.
Save glennposadas/bd7bab55e15003a22bff05525f5532d8 to your computer and use it in GitHub Desktop.
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool {
// Get view controllers from storyboard
let storyboard = UIStoryboard(name: "Main", bundle: nil)
let rootViewController = storyboard.instantiateViewControllerWithIdentifier("RootViewController") as! RootViewController
let sideViewController = storyboard.instantiateViewControllerWithIdentifier("SideViewController") as! SideViewController
let sideNavigationController = SideNavigationController(rootViewController: rootViewController, leftViewController: sideViewController)
// Configure the window with the SideNavigationController as the root view controller
window = UIWindow(frame: UIScreen.mainScreen().bounds)
window?.rootViewController = sideNavigationController
window?.makeKeyAndVisible()
return true
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment