Index: main.cpp =================================================================== diff -u -reea63d68fc0fb269f8dec64d99f488bcad117220 -rd3f916066c2d10c10fffa91fd8a7e5ac6dd86c7d --- main.cpp (.../main.cpp) (revision eea63d68fc0fb269f8dec64d99f488bcad117220) +++ main.cpp (.../main.cpp) (revision d3f916066c2d10c10fffa91fd8a7e5ac6dd86c7d) @@ -202,13 +202,21 @@ app.thread()->setObjectName("Main Thread"); //! - Setting the application version regarding the Bamboo build number. + QString ver_major = QString("%1").arg(VER_MAJOR); + if (ver_major.isEmpty()) { + ver_major = VER_MAJOR_DEV; + } + QString ver_minor = QString("%1").arg(VER_MINOR); + if (ver_minor.isEmpty()) { + ver_minor = VER_MINOR_DEV; + } QString ver_revis = QString("%1").arg(VER_REVIS); if (ver_revis.isEmpty()) { - ver_revis = VER_DEVEL; + ver_revis = VER_REVIS_DEV; } QCoreApplication::setApplicationVersion(QString("%1.%2.%3") - .arg(VER_MAJOR) - .arg(VER_MINOR) + .arg(ver_major) + .arg(ver_minor) .arg(ver_revis)); //! - Parse the command line arguments @@ -265,21 +273,11 @@ _MainTimer.init(); //! - Initialize the Qml Viewer and starts GUI - startGui(); + int app_exec = -1; + if ( startGui() ) { + app_exec = app.exec(); + } - - qDebug() << "\n _Logger :" << _Logger .thread()->objectName() - << "\n _USBWatcher :" << _USBWatcher .thread()->objectName() - << "\n _CanInterface :" << _CanInterface .thread()->objectName() - << "\n _FrameInterface :" << _FrameInterface .thread()->objectName() - << "\n _MessageAcknowModel :" << _MessageAcknowModel .thread()->objectName() - << "\n _MessageDispatcher :" << _MessageDispatcher .thread()->objectName() - << "\n _ApplicationController :" << _ApplicationController .thread()->objectName() - << "\n _GuiController :" << _GuiController .thread()->objectName() - ; - - int app_exec = app.exec(); - // Due to Qt Error the CAN Device cannot be disable/enable from withing another thread // (other than main thread which is the owner of the CanDevice). // So it needs to be done here in main thread.