AXWebViewController icon indicating copy to clipboard operation
AXWebViewController copied to clipboard

导航栏设置为透明色后变成了黑色

Open iBinbro opened this issue 7 years ago • 1 comments

代码如下:

AXWebViewController *webVC = [AXWebViewController sharedManagerWithUrl:@"http://www.baidu.com"];
    webVC.enabledWebViewUIDelegate = YES;
    webVC.showsToolBar = NO;
    webVC.showsBackgroundLabel = NO;
    if (AX_WEB_VIEW_CONTROLLER_iOS9_0_AVAILABLE()) {
        webVC.webView.allowsLinkPreview = YES;
    }
    webVC.navigationType = AXWebViewControllerNavigationBarItem;
    UINavigationController *nav = [[UINavigationController alloc]initWithRootViewController:webVC];
    webVC.navigationController.navigationBar.translucent = NO;
    webVC.navigationController.navigationBar.barTintColor = [UIColor clearColor];
    webVC.navigationController.navigationBar.tintColor = [UIColor clearColor];
    
    self.window = [[UIWindow alloc] init];
    self.window.backgroundColor = [UIColor whiteColor];
    self.window.frame = [UIScreen mainScreen].bounds;
    self.window.rootViewController = nav;
    [self.window makeKeyAndVisible];

//webVC.navigationController.navigationBar.barTintColor = [UIColor clearColor]; 这个如果设置成其他有色可正常显示,但是设置成透明色就会变成黑色,求解 o(╥﹏╥)o

iBinbro avatar Sep 07 '18 20:09 iBinbro

webVC.navigationController.navigationBar.translucent = NO; 这里设置给YES

zhaokunhaoa avatar Nov 16 '18 01:11 zhaokunhaoa