Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
386 views
in Technique[技术] by (71.8m points)

ios8 - Status Bar showing black text, only on iPhone 6 iOS 8 simulator

I'm trying to convert my iOS 7 app to iOS 8 in Xcode 6 GM, and when i run it on the iPhone 5s or lower simulators with iOS 8 everything is fine, but on the iPhone 6 and 6 Plus simulators, the Status Bar has black text instead of white like it is everywhere anytime else. I've set the Info.plist UIStatusBarStyle to "Transparent Black Style (alpha of 0.5)" thru Xcode, and that seems to have the desired effect everywhere else. Any ideas what is going on?

(I haven't touched any of the storyboards yet, could it be anything with that? I was hoping I could put that off for a while:)

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

So here is how I fixed it

In PLIST View Controller Based Status Bar NO Status Bar Style UIStatusBarStyleLightContent

In AppDelegate DidFinishLaunching

[UIApplication sharedApplication].statusBarStyle = UIStatusBarStyleLightContent;
    [self.window setBackgroundColor:[UIColor whiteColor]];

In Each View Controller

- (UIStatusBarStyle) preferredStatusBarStyle {
    return UIStatusBarStyleLightContent;
}

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...