问题背景:
在使用UITabBarController和UINavigationController的组合时,如果在UINavigationController push页面前(使用segue实现跳转是一样的)为了在下一个页面不显示TabBar而设置了setHidesBottomBarWhenPushed为YES,就会导致导航栏的过渡动画里出现黑色。
问题原因:
黑色是在发生动画时漏出了底部window的background
解决方案:
在AppDelegate的- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions中设置为白色或其它颜色:self.window.backgroundColor = [UIColor whiteColor];
网友评论