I'm purposefully hiding my tab-bar upon viewing a controller consisting of a UIWebView
:
- (void)viewWillAppear:(BOOL)animated{
self.hidesBottomBarWhenPushed = YES;
self.tabBarController.tabBar.hidden = YES;
self.url = [NSURL URLWithString:self.urlString];
}
In my storyboard, for this controller, I've set the bottom bar to be "None":
My storyboard shows that the web-view is now taking up all available space at the bottom:
However, I know have a black bar where my tab bar used to be:
Does anyone know why??
Setting hidesBottomBarWhenPushed
to YES
in viewWillAppear
doesn't do anything.
Set hidesBottomBarWhenPushed
to YES
before you push to this view controller.
MyViewController *myController = [[MyViewController alloc] init];
//hide tabbar
myController.hidesBottomBarWhenPushed = YES;
//add it to stack.
[[self navigationController] pushViewController:myController animated:YES];
Or in storyboard like this