[Solved] [iOS] Dealing with status bar in iOS6/7

Discussion of issues specific to mobile platforms such as iOS, Android, Symbian and Meego.
Post Reply
simedj
Goblin
Posts: 262
Joined: Fri Nov 18, 2011 6:50 pm
x 3

[Solved] [iOS] Dealing with status bar in iOS6/7

Post by simedj »

The way the status bar behaves in iOS7 is quite different, it sits on top of the view you render to which means if you have GUI at the top of your app, it is overlapped in a nasty way.

This SO post discusses it in some depth but since Ogre creates its own view how should Ogre users respond to this? You can (I think) hide the status bar entirely which is what (I think) iPad does in iOS6 but otherwise if you want to support iOS6 and iOS7 it seems a bit tricky - you run the risk of having to do hacky things like add a 20px buffer to the top of your GUI, ugh.

Should Ogre itself address this in some way so that each developer doesn't have to hack this? Or if not, how would I hack this given that Ogre creates the View deep in the heart of GLES2 render-system?
Last edited by simedj on Tue Mar 11, 2014 2:25 am, edited 2 times in total.
Looking to find experienced Ogre & shader developers/artists. PM me with a contact email address if interested.
User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 99
Contact:

Re: [iOS] Dealing with status bar in iOS6/7

Post by Wolfmanfx »

You can provide a custom viewcontroller/view so ogre wiuld not create it.
simedj
Goblin
Posts: 262
Joined: Fri Nov 18, 2011 6:50 pm
x 3

Re: [iOS] Dealing with status bar in iOS6/7

Post by simedj »

I could, but I'd rather not if possible - a big benefit of Ogre is I don't need to know how to create a HWND or a ViewController or other OS-specific stuff. You do that when you have atypical needs only.

Is the expectation is Ogre iApps would just hide the status bar and avoid the problem?
Looking to find experienced Ogre & shader developers/artists. PM me with a contact email address if interested.
User avatar
masterfalcon
OGRE Team Member
OGRE Team Member
Posts: 4270
Joined: Sun Feb 25, 2007 4:56 am
Location: Bloomington, MN
x 126
Contact:

Re: [iOS] Dealing with status bar in iOS6/7

Post by masterfalcon »

In your apps Info.plist just add this key:

UIViewControllerBasedStatusBarAppearance

And set it to NO. That should hide the status bar.
simedj
Goblin
Posts: 262
Joined: Fri Nov 18, 2011 6:50 pm
x 3

Re: [iOS] Dealing with status bar in iOS6/7

Post by simedj »

Problem solved - or at least averted :)
Looking to find experienced Ogre & shader developers/artists. PM me with a contact email address if interested.
Post Reply