I have a few tabs set up and there are just enough of them to require a more tab.

The more tab; however does not seem to have the same navbar coloration as my other tabs do.

From what I discovered from other searches the only way to do this is by writing:

UINavigationController* moreBar = self.tabBarControlelrVC.moreNavigationController;
moreBar.navigationBar.barStyle = UIBarStyleBlack;

I put that in my viewDidLoad of my appDelegate; but to no avail...

anyone got any good posts or ideas on this? Thanks.

有帮助吗?

解决方案

You'll need to set it like so:

in didFinishLaunchingWithOptions:

tabBarController = (UITabBarController *) self.window.rootViewController;

 // Set the color of the navigationbar in moretab
 UINavigationController *moreBar = tabBarController.moreNavigationController;
 moreBar.navigationBar.barStyle = UIBarStyleBlack;

or the other properties...

 moreBar.navigationBar.tintColor = [UIColor orangeColor];
 moreBar.navigationBar.hidden = NO;
 moreBar.navigationBar.backgroundColor = [UIColor blackColor];
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top