Browse Source

Fixes topBar.backgroundColor overrides topBar.noBorder

yogevbd 6 years ago
parent
commit
7dfec40722
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      lib/ios/RNNNavigationController.m

+ 2
- 2
lib/ios/RNNNavigationController.m View File

@@ -125,8 +125,8 @@ const NSInteger TOP_BAR_TRANSPARENT_TAG = 78264803;
125 125
 		UIView *transparentView = [self.navigationBar viewWithTag:TOP_BAR_TRANSPARENT_TAG];
126 126
 		if (transparentView){
127 127
 			[transparentView removeFromSuperview];
128
-			[self.navigationBar setBackgroundImage:self.originalTopBarImages[@"backgroundImage"] forBarMetrics:UIBarMetricsDefault];
129
-			self.navigationBar.shadowImage = self.originalTopBarImages[@"shadowImage"];
128
+			[self.navigationBar setBackgroundImage:self.originalTopBarImages[@"backgroundImage"] ? self.originalTopBarImages[@"backgroundImage"] : [self.navigationBar backgroundImageForBarMetrics:UIBarMetricsDefault] forBarMetrics:UIBarMetricsDefault];
129
+			self.navigationBar.shadowImage = self.originalTopBarImages[@"shadowImage"] ? self.originalTopBarImages[@"shadowImage"] : self.navigationBar.shadowImage;
130 130
 			self.originalTopBarImages = nil;
131 131
 		}
132 132
 	}