Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

your demo can't run, I fixed it !Please see the code in my comment. #72

Open
zxwcool opened this issue Jan 23, 2016 · 1 comment
Open

Comments

@zxwcool
Copy link

zxwcool commented Jan 23, 2016

There is no root view controller in your application delegate, so your demo crashed and I fixed it!

  • (BOOL)application:(UIApplication )application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
    {
    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
    self.window.backgroundColor = [UIColor whiteColor];
    .............
    .............
    .............
    UIViewController
    rootCtr = [[UIViewController alloc] init];
    UINavigationController* nav = [[UINavigationController alloc] initWithRootViewController:rootCtr];
    [rootCtr.view addSubview:menu];
    [self.window setRootViewController:nav];
    // [self.window addSubview:menu];
    [self.window makeKeyAndVisible];
    return YES;
    }
@Huang-Libo
Copy link

(BOOL)application:(UIApplication )application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
self.window.backgroundColor = [UIColor whiteColor];
.............
.............
.............
UIViewController *rootCtr = [[UIViewController alloc] init];
UINavigationController* nav = [[UINavigationController alloc] initWithRootViewController:rootCtr];
[rootCtr.view addSubview:menu];
[self.window setRootViewController:nav];
// [self.window addSubview:menu];
[self.window makeKeyAndVisible];
return YES;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants