mikefrederick / MFSideMenu

Facebook-like side menu for iOS
Other
1.17k stars 291 forks source link

Center view no longer expanding vertically on simulator 4 #171

Open cblaze22 opened 10 years ago

cblaze22 commented 10 years ago

ios simulator screen shot sep 9 2014 10 52 17 pm

The image above inserted this menu code and now the center view doesnt expand all the way to the bottom. Any clue on this?

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {    

    EventsViewController *eventsViewController = [[EventsViewController alloc] init];
    SideMenuViewController *leftSideMenuController = [[SideMenuViewController alloc] init];

    MFSideMenuContainerViewController *menuViewController = [MFSideMenuContainerViewController
                                                    containerWithCenterViewController:eventsViewController
                                                    leftMenuViewController:leftSideMenuController
                                                    rightMenuViewController:nil];

    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];

    [self.window setRootViewController:menuViewController];
    [self.window makeKeyAndVisible];

    return YES;
}
cblaze22 commented 10 years ago

Looks like it has to be a navigation controller.

EventsViewController *eventsViewController = [[EventsViewController alloc] init];
    UINavigationController *centerViewController = [[UINavigationController alloc] initWithRootViewController:eventsViewController];
    SideMenuViewController *leftSideMenuController = [[SideMenuViewController alloc] init];

    MFSideMenuContainerViewController *menuViewController = [MFSideMenuContainerViewController
                                                    containerWithCenterViewController:centerViewController
                                                    leftMenuViewController:leftSideMenuController
                                                    rightMenuViewController:nil];