#import "AppDelegate.h"
#import "CPNavigationBar.h"
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
// Setup Core Data.
// Display the main screen.
CPClientViewController *masterView = [[CPClientViewController alloc] init];
CPWelcomeView *detailView = [[CPWelcomeView alloc] init];
UINavigationController *leftNavigation = [[UINavigationController alloc]initWithNavigationBarClass:[CPNavigationBar class] toolbarClass:nil];
UINavigationController *rightNavigation = [[UINavigationController alloc]init];
[rightNavigation setViewControllers:@[detailView]];
leftNavigation.viewControllers = @[masterView];
UISplitViewController *splitView = [[UISplitViewController alloc] init];
splitView.viewControllers = [NSArray arrayWithObjects:leftNavigation, rightNavigation, nil];
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
[self.window setRootViewController:splitView];
[self.window makeKeyAndVisible];
return YES;
}