From 94217b294ccd75a34787eb04d6e273e99536e45b Mon Sep 17 00:00:00 2001
From: 重庆迈尖科技有限公司
Date: 星期三, 30 一月 2019 15:12:32 +0800
Subject: [PATCH] no message

---
 BuWanVideo2.0/BaseViewController.m |   16 +++++++++++++---
 1 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/BuWanVideo2.0/BaseViewController.m b/BuWanVideo2.0/BaseViewController.m
index 8a635a8..9239b74 100644
--- a/BuWanVideo2.0/BaseViewController.m
+++ b/BuWanVideo2.0/BaseViewController.m
@@ -19,11 +19,15 @@
 
 - (void)viewDidLoad {
     [super viewDidLoad];
+
+}
+- (void)viewWillAppear:(BOOL)animated{
+//    self.navigationController.navigationBar.translucent = NO;
     self.dataHot = @[].mutableCopy;
     [self getHotSearch];
     [self loadNavigationbar];
-}
 
+}
 -(void)loadNavigationbar{
     //鍘绘帀titlie
     UIView *tview = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 0.01, 0.01)];
@@ -33,16 +37,23 @@
     [[UINavigationBar appearance] setShadowImage:[[UIImage alloc] init]];
     //    鍒涘缓涓�涓珮20鐨勫亣鐘舵�佹爮
     UIView *statusBarView = [[UIView alloc] initWithFrame:CGRectMake(0, -20, KScreenW, 20)];
+//    CGRect statusBarFrame = [[UIApplication sharedApplication] statusBarFrame];
+//    statusBarView.frame = statusBarFrame;
+    if (KIsiPhoneX) {
+        statusBarView.frame = CGRectMake(0, -44, KScreenW, 44);
+    }
+    NSLog(@"%f == %f  \n  %f === %f",KScreenH,KScreenW,[[UIScreen mainScreen] currentMode].size.height,[[UIScreen mainScreen] currentMode].size.width);
     //    璁剧疆棰滆壊
     statusBarView.backgroundColor=kGlobalMainColor;
     [self.navigationController.navigationBar setBackgroundColor:kGlobalMainColor];
+//    [self.navigationController.navigationBar setBackgroundColor:[UIColor orangeColor]];
+
     [self.navigationController.navigationBar addSubview:statusBarView];
     //鎼滅储
     UIView *seachView = [[UIView alloc]initWithFrame:CGRectMake(0, 0,  KScreenW / 5 * 4, 30)];
     self.searchText = [[UITextField alloc]initWithFrame:CGRectMake(0, 0,seachView.frame.size.width, seachView.frame.size.height)];
     self.searchText.backgroundColor = [UIColor colorWithWhite:0.7 alpha:0.2];
     self.searchText.layer.cornerRadius = self.searchText.frame.size.height / 2;
-
     self.searchText.textColor = [UIColor whiteColor];
     self.searchText.font = [UIFont systemFontOfSize:14];
     UIView *leftView = [[UIView alloc]initWithFrame:CGRectMake(0, 0, 45, 25)];
@@ -83,7 +94,6 @@
     UILabel *WhiteLabel1=[[UILabel alloc] initWithFrame:CGRectMake(0, 0, 20, 10)];
     WhiteLabel1.backgroundColor=[UIColor clearColor];
     UIBarButtonItem *WhiteBarItem1=[[UIBarButtonItem alloc] initWithCustomView:WhiteLabel1];
-    
     //娣诲姞 瑙傜湅璁板綍/涓嬭浇/鎼滅储 鍒板鑸爮
     self.navigationItem.rightBarButtonItems=[[NSArray alloc] initWithObjects:recordBarItem,searchItem,WhiteBarItem,nil];
 }

--
Gitblit v1.8.0