summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms
diff options
context:
space:
mode:
authorRichard Moe Gustavsen <richard.gustavsen@digia.com>2013-11-26 11:13:56 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-12-04 14:50:43 +0100
commit2e132854460e11a1ade516f61477723202d56a93 (patch)
tree47378ecd8b41d905681e77414012ffeff67a562b /src/plugins/platforms
parent996d78d4c94a0116eecec160caf605ea3629f36c (diff)
iOS: don't show statusbar if hidden from Info.plist
Currently there is no way to always hide the statusbar on iOS other than showing a window in fullscreen. This patch will check if the statusbar is (initially) hidden from the Info.plist, and respect that in the application. SubAttack is an example of an app that (because of styling issues with MainWindow margins) manually sets the geometry larger than fullsreen, and calls showNormal(). In that case we still want the statusbar to be hidden. Change-Id: Ia365d14971978360d0b39621ff0f8f82f74b57e2 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
Diffstat (limited to 'src/plugins/platforms')
-rw-r--r--src/plugins/platforms/ios/qiosviewcontroller.mm3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/plugins/platforms/ios/qiosviewcontroller.mm b/src/plugins/platforms/ios/qiosviewcontroller.mm
index 9a9fba5a8e..0a6a00b753 100644
--- a/src/plugins/platforms/ios/qiosviewcontroller.mm
+++ b/src/plugins/platforms/ios/qiosviewcontroller.mm
@@ -101,6 +101,9 @@
- (BOOL)prefersStatusBarHidden
{
+ static bool hiddenFromPlist = infoPlistValue(@"UIStatusBarHidden", false);
+ if (hiddenFromPlist)
+ return YES;
QWindow *focusWindow = QGuiApplication::focusWindow();
if (!focusWindow || !focusWindow->handle())
return [UIApplication sharedApplication].statusBarHidden;