Skip to content

Commit 57bc5b3

Browse files
committed
TRIVIAL: Make size change demo optional
1 parent 596ecf2 commit 57bc5b3

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

FRLayeredNavigationControllerDemo/AppDelegate.m

+17-1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@
3030

3131
#import "MainViewController.h"
3232

33+
#import "SampleListViewController.h"
34+
35+
//Wheather to demo size changes or not...
36+
//#define DEMO_SIZE_CHANGES
37+
3338
@implementation AppDelegate
3439

3540
@synthesize window = _window;
@@ -40,9 +45,20 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
4045
// Override point for customization after application launch.
4146
self.window.backgroundColor = [UIColor whiteColor];
4247

48+
#ifdef DEMO_SIZE_CHANGES
4349
MainViewController *vc = [[MainViewController alloc] init];
4450
self.window.rootViewController = vc;
45-
51+
#else
52+
UIViewController *vc = [[SampleListViewController alloc] init];
53+
FRLayeredNavigationController *fvc = [[FRLayeredNavigationController alloc]
54+
initWithRootViewController:vc
55+
configuration:^(FRLayeredNavigationItem *item) {
56+
item.width = 200; //600;
57+
item.nextItemDistance = 64; //2;
58+
}];
59+
self.window.rootViewController = fvc;
60+
self.window.backgroundColor = [UIColor scrollViewTexturedBackgroundColor];
61+
#endif
4662
[self.window makeKeyAndVisible];
4763

4864
return YES;

0 commit comments

Comments
 (0)