diff --git a/qgroundcontrol.pro b/qgroundcontrol.pro index f61044ca6ddf76c166633b77f3b4882737a94fdd..659bfbf3182c99c68de4c1b65216fdf168b63d64 100644 --- a/qgroundcontrol.pro +++ b/qgroundcontrol.pro @@ -297,8 +297,7 @@ HEADERS += \ src/AutoPilotPlugins/APM/APMAirframeLoader.h \ src/QmlControls/QGCImageProvider.h \ src/AutoPilotPlugins/APM/APMRemoteParamsDownloader.h \ - src/QtLocationPlugin/QMLControl/QGCMapEngineManager.h \ - src/ViewWidgets/AppMessagesDialog.h + src/QtLocationPlugin/QMLControl/QGCMapEngineManager.h DebugBuild { HEADERS += \ @@ -371,6 +370,7 @@ HEADERS += \ src/ViewWidgets/LogDownload.h \ src/ViewWidgets/LogDownloadController.h \ src/ViewWidgets/ViewWidgetController.h \ + src/ViewWidgets/AppMessagesDialog.h } iOSBuild { @@ -437,8 +437,7 @@ SOURCES += \ src/AutoPilotPlugins/APM/APMAirframeLoader.cc \ src/QmlControls/QGCImageProvider.cc \ src/AutoPilotPlugins/APM/APMRemoteParamsDownloader.cc \ - src/QtLocationPlugin/QMLControl/QGCMapEngineManager.cc \ - src/ViewWidgets/AppMessagesDialog.cc + src/QtLocationPlugin/QMLControl/QGCMapEngineManager.cc DebugBuild { SOURCES += \ @@ -504,6 +503,7 @@ SOURCES += \ src/ViewWidgets/LogDownload.cc \ src/ViewWidgets/LogDownloadController.cc \ src/ViewWidgets/ViewWidgetController.cc \ + src/ViewWidgets/AppMessagesDialog.cc } # diff --git a/src/QGCDockWidget.h b/src/QGCDockWidget.h index e8fde455888c328bd7c708a8e6e9bb01ce9d4c67..5eca0eec21160af4071607898b45a53c1776ea99 100644 --- a/src/QGCDockWidget.h +++ b/src/QGCDockWidget.h @@ -26,6 +26,7 @@ #include #include +#include class QGCDockWidget : public QWidget { Q_OBJECT @@ -38,10 +39,10 @@ public: void saveSettings(void); void closeEvent(QCloseEvent* event); - + protected: QString _title; - QPointer _action; + QPointer _action; static const char* _settingsGroup; }; diff --git a/src/ViewWidgets/appmessagesdialog.cc b/src/ViewWidgets/AppMessagesDialog.cc similarity index 100% rename from src/ViewWidgets/appmessagesdialog.cc rename to src/ViewWidgets/AppMessagesDialog.cc diff --git a/src/ViewWidgets/appmessagesdialog.h b/src/ViewWidgets/AppMessagesDialog.h similarity index 100% rename from src/ViewWidgets/appmessagesdialog.h rename to src/ViewWidgets/AppMessagesDialog.h diff --git a/src/main.cc b/src/main.cc index 7ccdab5361f9f12b47a046b07c8e8fcb81af7de5..abbbd1eee3fa39ce4795de2222abefe9329dc49c 100644 --- a/src/main.cc +++ b/src/main.cc @@ -36,13 +36,13 @@ This file is part of the QGROUNDCONTROL project #include #include #include -#include "AppMessagesDialog.h" #include "QGCApplication.h" #define SINGLE_INSTANCE_PORT 14499 #ifndef __mobile__ #include "QGCSerialPortInfo.h" + #include "AppMessagesDialog.h" #endif #ifdef QT_DEBUG @@ -116,6 +116,9 @@ int main(int argc, char *argv[]) { #ifndef __mobile__ + // install the message handler + AppMessagesDialog::installHandler(); + //-- Test for another instance already running. If that's the case, we simply exit. QHostAddress host("127.0.0.1"); QUdpSocket socket; @@ -133,8 +136,6 @@ int main(int argc, char *argv[]) #endif #endif - // install the message handler - AppMessagesDialog::installHandler(); #ifdef Q_OS_WIN // Set our own OpenGL buglist qputenv("QT_OPENGL_BUGLIST", ":/opengl/resources/opengl/buglist.json");