diff options
author | con <qtc-committer@nokia.com> | 2011-03-22 10:07:00 (GMT) |
---|---|---|
committer | con <qtc-committer@nokia.com> | 2011-03-22 10:07:45 (GMT) |
commit | 07b5eac8a85088a928d04b84be9cc082e4500978 (patch) | |
tree | 969d5a834a8df3b1e0a8449030bb37578715942c | |
parent | dc1f979b7d2d13efd852fd3fa41930f115a9edd1 (diff) | |
download | Qt-07b5eac8a85088a928d04b84be9cc082e4500978.zip Qt-07b5eac8a85088a928d04b84be9cc082e4500978.tar.gz Qt-07b5eac8a85088a928d04b84be9cc082e4500978.tar.bz2 |
Use the new QT_QPA_DEFAULT_PLATFORM_NAME define.
-rw-r--r-- | mkspecs/qws/macx-iphonedevice-g++/qplatformdefs.h | 2 | ||||
-rw-r--r-- | mkspecs/qws/macx-iphonesimulator-g++/qplatformdefs.h | 2 | ||||
-rw-r--r-- | src/plugins/platforms/uikit/examples/qmltest/main.mm | 16 |
3 files changed, 7 insertions, 13 deletions
diff --git a/mkspecs/qws/macx-iphonedevice-g++/qplatformdefs.h b/mkspecs/qws/macx-iphonedevice-g++/qplatformdefs.h index 425fda3..0468935 100644 --- a/mkspecs/qws/macx-iphonedevice-g++/qplatformdefs.h +++ b/mkspecs/qws/macx-iphonedevice-g++/qplatformdefs.h @@ -94,4 +94,6 @@ #define QT_SNPRINTF ::snprintf #define QT_VSNPRINTF ::vsnprintf +#define QT_QPA_DEFAULT_PLATFORM_NAME "uikit" + #endif // QPLATFORMDEFS_H diff --git a/mkspecs/qws/macx-iphonesimulator-g++/qplatformdefs.h b/mkspecs/qws/macx-iphonesimulator-g++/qplatformdefs.h index 425fda3..0468935 100644 --- a/mkspecs/qws/macx-iphonesimulator-g++/qplatformdefs.h +++ b/mkspecs/qws/macx-iphonesimulator-g++/qplatformdefs.h @@ -94,4 +94,6 @@ #define QT_SNPRINTF ::snprintf #define QT_VSNPRINTF ::vsnprintf +#define QT_QPA_DEFAULT_PLATFORM_NAME "uikit" + #endif // QPLATFORMDEFS_H diff --git a/src/plugins/platforms/uikit/examples/qmltest/main.mm b/src/plugins/platforms/uikit/examples/qmltest/main.mm index 6fd5629..2b5f024 100644 --- a/src/plugins/platforms/uikit/examples/qmltest/main.mm +++ b/src/plugins/platforms/uikit/examples/qmltest/main.mm @@ -39,14 +39,6 @@ ** ****************************************************************************/ -// -// main.m -// qmltest -// -// Created by Eike Troll on 18.02.11. -// Copyright 2011 __MyCompanyName__. All rights reserved. -// - #import <UIKit/UIKit.h> #include "qmlapplicationviewer/qmlapplicationviewer.h" @@ -60,15 +52,13 @@ int main(int argc, char *argv[]) { NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; - setenv("QT_QPA_PLATFORM","uikit",1); - - QApplication app(argc, argv); + QApplication app(argc, argv); QmlApplicationViewer viewer; viewer.setOrientation(QmlApplicationViewer::ScreenOrientationAuto); - NSString *resourcePath = [[NSBundle mainBundle] resourcePath]; + NSString *resourcePath = [[NSBundle mainBundle] resourcePath]; viewer.setMainQmlFile(QString::fromUtf8([[resourcePath stringByAppendingPathComponent:@"qml/main.qml"] UTF8String])); viewer.showMaximized(); - int retVal = app.exec(); + int retVal = app.exec(); [pool release]; return retVal; } |