views:

86

answers:

1

Hi, My application consists out of a tabbarcontroller and inside i got multiple navigationControllers. Now i want to hide the bottom bar of the tabbarcontroller from the start because the buttons on the bottom bar lead to features inside the application which are just not ready yet so i dont't want the user to see them. How do i do this? Thanks in advance!

A: 

A couple of options:

  • Set hidesBottomBarWhenPushed=YES on one of the controllers in your navigation controller. I'm not sure if this works on the root view controller of a navigation controller.
  • Hide the tab bar items by changing UITabBarController.viewControllers. I'm not sure if it lets you have a tab bar with only one tab, but it ought to.
  • Set the tab bar controller's delegate (see UITabBarControllerDelegate). In – tabBarController:shouldSelectViewController:, return NO if it hasn't been implemented yet.
tc.
- setting hidesBottomBarWhenPushed doesn't work because then the user is definitely going to see the tabBar once when the application was launched. Once he has navigated forth and back to the navigationController the tabBar will be gone, but i want it to be gone from the start. - Hiding the tabBar items does work but then there's still the black bar on the bottom which is kind of annoying. - returning NO in the described delegate method doesn't do anything for some reason..... is there any other option?
Christoph v
You can always have a "dummy" root view controller and push the real root view controller on top of that. If you set `self.navigationItem.hidesBackButton`, then the user can never pop to the dummy root, and will never see the tab bar.
tc.