iOS 8 状态栏保持黑底白字 亲测有效
生活随笔
收集整理的這篇文章主要介紹了
iOS 8 状态栏保持黑底白字 亲测有效
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
1.info.plist文件 ?設置View controller-based status bar appearance的值為no
2.在AppDelegate.m中添加如下代碼
if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7) {[application setStatusBarStyle:UIStatusBarStyleLightContent];self.window.clipsToBounds =YES;self.window.frame = CGRectMake(0,20,self.window.frame.size.width,self.window.frame.size.height-20);self.window.bounds = CGRectMake(0, 20, self.window.frame.size.width, self.window.frame.size.height);}
效果如下圖:
總結
以上是生活随笔為你收集整理的iOS 8 状态栏保持黑底白字 亲测有效的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: micropython 播放音乐_用 p
- 下一篇: 大众点评网