Created
February 19, 2015 00:52
-
-
Save alimoeeny/85b107ddabc345f766e1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var window: UIWindow? | |
var sideMenuViewController: RESideMenu? | |
var rootTabVC: UITabBarController? | |
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { | |
// about | |
var about : AboutViewController = AboutViewController(nibName: "AboutView_iphone", bundle: nil) | |
about.title = "About" | |
// tutorial | |
var tutorial: TutorialViewController = TutorialViewController(nibName: "TutorialView_iphone", bundle: nil) | |
tutorial.title = "Tutorial" | |
rootTabVC = UITabBarController() | |
rootTabVC?.tabBar.hidden = true | |
rootTabVC?.addChildViewController(about) // 0 | |
rootTabVC?.addChildViewController(tutorial) // 1 | |
window = UIWindow(frame: UIScreen.mainScreen().bounds) | |
// side menus --------------------------------------------------------------- | |
let lmVC = LeftMenuViewController(nibName: "LeftMenuView_iphone", bundle: nil) | |
let rmVC = RightMenuViewController(nibName: "RightMenuView_iphone", bundle: nil) | |
sideMenuViewController = RESideMenu( | |
contentViewController: rootTabVC, | |
leftMenuViewController: lmVC, | |
rightMenuViewController: rmVC) | |
window?.rootViewController = sideMenuViewController; | |
// side menus ---------------------------------------------------------------- | |
window?.makeKeyAndVisible() | |
return true | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I added RESideMenu to my iPhone version and it works and looks great! It is especially valuable because there are options like select a trip, settings and share that should be available for all tabs and was not possible before with just the left and right bar button items. Thanks again and I look forward to showing it to you next time.