I've placed this code my applicationDidFinishLaunching method, to get a black Navigationbar.
rootTabBarController.navigationController.navigationBar.barStyle = UIBarStyleBlackOpaque;
rootTabBarController.moreNavigationController.navigationBar.barStyle = UIBarStyleBlackOpaque;
its working fine, but when the user rearranges the Icons in the editmode, i'm getting a default blue navigation bar.
Can anyone help me to avid blue navigationbars at all ?
btw: big thanks to the geni开发者_开发问答us crowd!
finally i have a solution, thx to AAA4 from apple forum
Implement the following delegate method in application delegate class: Please ensure you have set delegate of UITabBarController
- (void)tabBarController:(UITabBarController *)controller willBeginCustomizingViewControllers:(NSArray *)viewControllers {
UIView *editView = [controller.view.subviews objectAtIndex:1];
// change backgroundColor of Edit View
editView.backgroundColor = [UIColor grayColor];
// change color of Nav Bar in Edit View
UINavigationBar *modalNavBar = [editView.subviews objectAtIndex:0];
modalNavBar.tintColor = [UIColor orangeColor];
// change title of Edit View
modalNavBar.topItem.title = @"Edit Tabs";
}
精彩评论