diff options
Diffstat (limited to 'src/plugins/platforms/ios/qiosapplicationdelegate.mm')
-rw-r--r-- | src/plugins/platforms/ios/qiosapplicationdelegate.mm | 44 |
1 files changed, 14 insertions, 30 deletions
diff --git a/src/plugins/platforms/ios/qiosapplicationdelegate.mm b/src/plugins/platforms/ios/qiosapplicationdelegate.mm index 10cbe529c4..e06d2b8840 100644 --- a/src/plugins/platforms/ios/qiosapplicationdelegate.mm +++ b/src/plugins/platforms/ios/qiosapplicationdelegate.mm @@ -39,8 +39,11 @@ ** ****************************************************************************/ -#import "qiosapplicationdelegate.h" +#include "qiosapplicationdelegate.h" + +#include "qiosviewcontroller.h" #include "qioswindow.h" + #include <QtCore/QtCore> @implementation QIOSApplicationDelegate @@ -50,38 +53,20 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { - Q_UNUSED(application) - Q_UNUSED(launchOptions) + Q_UNUSED(application); + Q_UNUSED(launchOptions); - return YES; -} + self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease]; + self.qiosViewController = [[[QIOSViewController alloc] init] autorelease]; + self.window.rootViewController = self.qiosViewController; -- (void)applicationWillResignActive:(UIApplication *)application -{ - Q_UNUSED(application) -} +#ifdef QT_DEBUG + self.window.backgroundColor = [UIColor cyanColor]; +#endif -- (void)applicationDidEnterBackground:(UIApplication *)application -{ - Q_UNUSED(application) -} + [self.window makeKeyAndVisible]; -- (void)applicationWillEnterForeground:(UIApplication *)application -{ - Q_UNUSED(application) - // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. -} - -- (void)applicationDidBecomeActive:(UIApplication *)application -{ - Q_UNUSED(application) - // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. -} - -- (void)applicationWillTerminate:(UIApplication *)application -{ - Q_UNUSED(application) - // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + return YES; } - (void)dealloc @@ -93,4 +78,3 @@ @end - |