ridgerock
Veteran developer
Profile
Posts: 183
Reg: May 19, 2011
Louisville
1,830
09/28/21 09:25 AM (2 years ago)

iOS 15 Breaks NavBar Color and BottomBar Color

Ever since the new iOS 15 update, the NavBar and Bottom Button Bar is transparent and can not have a color set. Does anyone have a fix?
 
Cakebit
Code is Art
Profile
Posts: 500
Reg: Dec 15, 2010
In your local b...
16,500
like
10/08/21 02:52 AM (2 years ago)
Replace lines 269-273 in BT_viewController.m with the snippet below, to (hopefully!) fix the NavBar transparency issues: if([[BT_strings getStyleValueForScreen:self.screenData nameOfProperty:@"navBarStyle" defaultValue:@""] isEqualToString:@"solid"]){ if (@available(iOS 13.0, *)) { UINavigationBarAppearance *navBarAppearance = [[UINavigationBarAppearance alloc] init]; [navBarAppearance configureWithOpaqueBackground]; navBarAppearance.backgroundColor = [BT_color getColorFromHexString:tmpBarBackgroundColor]; [self.navigationController.navigationBar setScrollEdgeAppearance:navBarAppearance]; [self.navigationController.navigationBar setStandardAppearance:navBarAppearance]; } else { [self.navigationController.navigationBar setTranslucent:FALSE]; [self.navigationController.navigationBar setBarStyle:UIBarStyleBlackOpaque]; [self.navigationController.navigationBar setBarTintColor:[BT_color getColorFromHexString:tmpBarBackgroundColor]]; } } (Did the Bottom Button Bar have a color set previously, or did it inherit the NavBar color?)
 
ridgerock
Veteran developer
Profile
Posts: 183
Reg: May 19, 2011
Louisville
1,830
like
10/11/21 11:25 AM (2 years ago)
Awesome. That code appears to have fixed the NavBar at the top. Sorry, I probably should have been more clear on the Bottom Button Bar/Menu. It could not be assigned/inherit a color. Ever since the update, it has been permanently made transparent instead of white. Screenshots: Broken Bottom Menu: https://ibb.co/xCP6TTf Working Bottom Menu: https://ibb.co/KWNG4Q0 Thanks for your help!
 
Cakebit
Code is Art
Profile
Posts: 500
Reg: Dec 15, 2010
In your local b...
16,500
like
10/11/21 08:36 PM (2 years ago)
Great! Glad to know that helped! Here's a snippet to fix the tab bar being transparent in iOS 15: //make the tab bar behave like before iOS 15 changes if (@available(iOS 15.0, *)) { UITabBarAppearance *tabBarAppearance = [[UITabBarAppearance alloc] init]; [tabBarAppearance configureWithOpaqueBackground]; //customize the tab bar color... if(self.rootTheme != nil){ NSString *tabBarColor = [BT_strings getStyleValueForScreen:self.rootTheme nameOfProperty:@"tabBarColor" defaultValue:@""]; if([tabBarColor length] > 1){ UIColor *tmpColor = [BT_color getColorFromHexString:tabBarColor]; [tabBarAppearance setBackgroundColor:tmpColor]; } } [[self.rootTabBarController tabBar] setStandardAppearance:tabBarAppearance]; [[self.rootTabBarController tabBar] setScrollEdgeAppearance:tabBarAppearance]; } Just place it in BT_application.m around line 308. (Alternatively, I did add both the patches to the latest version of the Buzztouch iOS core... so you can re-download your application from your control panel to get these patches. :)
 
ridgerock
Veteran developer
Profile
Posts: 183
Reg: May 19, 2011
Louisville
1,830
like
10/12/21 07:44 AM (2 years ago)
Awesome, worked perfectly. A god sent.
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.