rod750
rod750

Reputation: 66

Cannot hide status bar cocos2d iOS 7

I tried to add View controller-based status bar appearance: NO and Status bar is initially hidden: YES to plist, [[UIApplication sharedApplication] setStatusBarHidden:YES withAnimation:UIStatusBarAnimationNone] and - (BOOL) prefersStatusBarHidden to CCDirectorIOS and AppDelegate, no one works.

There's something I am missing?

Upvotes: 0

Views: 397

Answers (2)

Renaissance
Renaissance

Reputation: 554

Add below given function to CCDirector.m file.

  • (BOOL)prefersStatusBarHidden {return YES;}

Upvotes: 4

Ben-G
Ben-G

Reputation: 5026

In your Info.plist set Status bar is initially hidden to YES and View controller-based status bar appearance to NO.

See more here: https://www.makegameswith.us/gamernews/279/hiding-status-bar-ccmenu-fix-ios7

Upvotes: 1

Related Questions