diff options
Diffstat (limited to 'Juick/AppDelegate.m')
-rw-r--r-- | Juick/AppDelegate.m | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/Juick/AppDelegate.m b/Juick/AppDelegate.m index 23cef5e..3fa3030 100644 --- a/Juick/AppDelegate.m +++ b/Juick/AppDelegate.m @@ -7,12 +7,36 @@ // #import "AppDelegate.h" -#import "MasterViewController.h" +#import "MessagesViewController.h" +#import "RevealPanelViewController.h" +#import "SWRevealViewController.h" @implementation AppDelegate - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { + // style the navigation bar + UIColor* navColor = [UIColor colorWithRed:44/255.0f green:44/255.0f blue:44/255.0f alpha:1]; + [[UINavigationBar appearance] setBarTintColor:navColor]; + [[UINavigationBar appearance] setTintColor:[UIColor colorWithRed:153/255.0f green:154/255.0f blue:153/255.0f alpha:1]]; + [[UINavigationBar appearance] setTitleTextAttributes:@{NSForegroundColorAttributeName: [UIColor colorWithRed:153/255.0f green:154/255.0f blue:153/255.0f alpha:1]}]; + + // make the status bar white + [UIApplication sharedApplication].statusBarStyle = UIStatusBarStyleLightContent; + + MessagesViewController *messages = [[MessagesViewController alloc] initWithURL:[NSURL URLWithString:@"https://api.juick.com/messages"]]; + RevealPanelViewController *rear = [[RevealPanelViewController alloc] init]; + + UINavigationController *main = [[UINavigationController alloc] initWithRootViewController:messages]; + UINavigationController *rearNav = [[UINavigationController alloc] initWithRootViewController:rear]; + + SWRevealViewController *reveal = [[SWRevealViewController alloc] initWithRearViewController:rearNav frontViewController:main]; + self.viewController = reveal; + + self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; + self.window.rootViewController = reveal; + [self.window makeKeyAndVisible]; + return YES; } |