1

I'm trying to get a view above the status bar in ios9:

UIWindow *statusWindow = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; statusWindow.windowLevel = UIWindowLevelStatusBar + 1; statusWindow.hidden = NO; statusWindow.backgroundColor = [UIColor colorWithWhite:0.0 alpha:0.7]; [statusWindow setRootViewController:self]; [statusWindow makeKeyAndVisible]; 

I only get a black screen with the status bar not covered. Any idea why it's not working ?

2 Answers 2

1

I am going to go ahead and assume you are writing your code based off of this thread:

Add UIView Above All Other Views, Including StatusBar

That being said, why are you setting:

statusWindow.windowLevel = UIWindowLevelStatusBar + 1; 

It should be:

statusWindow.windowLevel = UIWindowLevelStatusBar; 

In the future, please add references to any threads you have looked at as well.

Good luck!

Sign up to request clarification or add additional context in comments.

Comments

0

I found this : https://github.com/kevingibbon/KGStatusBar It works pretty well. It's the only framework I found which is working with iOS9.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.