diff options
author | Simon Hausmann <simon.hausmann@theqtcompany.com> | 2014-12-10 07:58:06 +0100 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@theqtcompany.com> | 2014-12-10 07:58:06 +0100 |
commit | 015002fec9abff6a4c1bb3fa4b9de87279a079c3 (patch) | |
tree | ad93af535a503d0a49d6c6367e990a8fbca163d3 /src/plugins/platforms/ios/qiosintegration.mm | |
parent | f1e00262321cc8daa3c7506153653453e2779886 (diff) | |
parent | b9547af45ea2bbbc634722c1ef41afdb54216ce2 (diff) |
Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
doc/global/template/style/online.css
mkspecs/android-g++/qmake.conf
Change-Id: Ib39ea7bd42f5ae12e82a3bc59a66787a16bdfc61
Diffstat (limited to 'src/plugins/platforms/ios/qiosintegration.mm')
-rw-r--r-- | src/plugins/platforms/ios/qiosintegration.mm | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/plugins/platforms/ios/qiosintegration.mm b/src/plugins/platforms/ios/qiosintegration.mm index 9a722ead37..461f160892 100644 --- a/src/plugins/platforms/ios/qiosintegration.mm +++ b/src/plugins/platforms/ios/qiosintegration.mm @@ -88,7 +88,13 @@ QIOSIntegration::QIOSIntegration() // Set current directory to app bundle folder QDir::setCurrent(QString::fromUtf8([[[NSBundle mainBundle] bundlePath] UTF8String])); - for (UIScreen *screen in [UIScreen screens]) + NSMutableArray *screens = [[[UIScreen screens] mutableCopy] autorelease]; + if (![screens containsObject:[UIScreen mainScreen]]) { + // Fallback for iOS 7.1 (QTBUG-42345) + [screens insertObject:[UIScreen mainScreen] atIndex:0]; + } + + for (UIScreen *screen in screens) addScreen(new QIOSScreen(screen)); // Depends on a primary screen being present |