How should I setup this “drawer” view app?
I am using a framework MMDrawerController which has been awesome. I am just trying to structure my code well. I have just the left side nav. And I have it setup like this right now:
UIViewController *leftSideDrawerViewController = [[MenuNavigationViewController alloc] initWithStyle:UITableViewStylePlain]; // ****************************** just my initial login viewcontroller UIViewController *centerViewController = [[***LoginViewController*** alloc] init];// The Question I have is right here // ****************************** UINavigationController *navigationController = [[UINavigationController alloc] initWithRootViewController:centerViewController]; self.drawerController = [[MMDrawerController alloc] initWithCenterViewController:navigationController leftDrawerViewController:leftSideDrawerViewController rightDrawerViewController:nil]; self.window setRootViewController:self.drawerController];
Should basically I just make my left view controller my MenuViewController which will never be changed. And then I make my center view controller my LoginViewController and this view will obviously need to be changed eventually. I have about 5 view controllers available to be selected in the left nav, then from those viewcontrollers accessed from the left nav, I will push viewcontrollers. How can I set this up? It seems to me like I would need multiple navigation controllers. One for each viewcontroller available in the left side nav.
How can I setup multiple navigation controllers and how can I transition between those navigation controllers on the center view?
Thanks for the help, just trying to setup this app well!!!
Answers
i think your requirement is something like this take a look at the below demo code that i've created hope it helps you :)
https://www.dropbox.com/s/7exzdzqnm6i05wd/DeckViewDemo%202.zip