logsui/logsapp/src/main.cpp
changeset 18 acd4e87b24b4
parent 17 90fe74753f71
child 21 2f0af9ba7665
--- a/logsui/logsapp/src/main.cpp	Fri Sep 03 14:26:05 2010 +0300
+++ b/logsui/logsapp/src/main.cpp	Fri Sep 17 16:47:32 2010 +0300
@@ -15,6 +15,7 @@
 *
 */
 //USER
+#include "logsappsettings.h"
 #include "logsapplication.h"
 #include "logsmainwindow.h"
 #include "logsviewmanager.h"
@@ -40,7 +41,8 @@
 {
     LOGS_QDEBUG( "logs [UI] -> main()" )
 
-    LogsApplication app(argc, argv);
+    LogsAppSettings appSettings(argc, argv);
+    LogsApplication app(argc, argv, appSettings);
 
 #ifdef LOGS_USE_QTRANSLATOR
     QString lang = QLocale::system().name();
@@ -65,7 +67,8 @@
     
     LogsMainWindow window;
     //Application ready signal is emitted after startup when UI is fully loaded and functional
-    QObject::connect( &window, SIGNAL(viewReady()), &app, SLOT(testLogsHandleAppViewReady()) );    
+    QObject::connect( &window, SIGNAL(viewReady()), &app, SLOT(testLogsHandleAppViewReady()) );  
+    QObject::connect( &window, SIGNAL(appLostForeground()), &app, SLOT(testLogsResetAppReady()) );
     HbStyleLoader::registerFilePath(":/logslayouts");
     
     // Create service handler asap so that services are published fast.
@@ -74,7 +77,7 @@
     // HbApplication creation takes long time.
     LogsServiceHandler service;
     LogsServiceHandlerOld serviceOld;
-    LogsViewManager viewManager(window, service, serviceOld);
+    LogsViewManager viewManager(window, service, serviceOld, appSettings);
     
     // Don't show window yet as app might be started at background
     int err = app.exec();