I have a view controller, in which the navigation bar is transparent. My next view is a table view, in which the navigation bar is white.
To stop an unwanted animation carrying over, I am setting the navigation bar to transparent in the 'viewDidDissapear' of the table view. Unfortunately this leaves me with the image below when I navigate back (its even worse when you navigate forward). Does anyone know how to get rid of the black area?
-(void)viewWillDisappear:(BOOL)animated {
[self.navigationController.navigationBar setBackgroundImage:[UIImage new]
forBarMetrics:UIBarMetricsDefault];
self.navigationController.navigationBar.shadowImage = [UIImage new];
self.navigationController.navigationBar.translucent = YES;
[super viewWillDisappear:NO];
}
This is the code I'm using in the table view controller.