Browse Source

moved RadioComponentController qml definition to FirmwarePlugin

Signed-off-by: numan.uyar <numan.uyar@titra.com.tr>
QGC4.4
numan.uyar 4 years ago committed by Don Gagne
parent
commit
815b2746b7
  1. 7
      src/FirmwarePlugin/FirmwarePlugin.cc
  2. 2
      src/FirmwarePlugin/FirmwarePlugin.h
  3. 2
      src/QGCApplication.cc

7
src/FirmwarePlugin/FirmwarePlugin.cc

@ -15,6 +15,7 @@ @@ -15,6 +15,7 @@
#include "AppSettings.h"
#include "QGCFileDownload.h"
#include "QGCCameraManager.h"
#include "RadioComponentController.h"
#include <QRegularExpression>
#include <QDebug>
@ -48,6 +49,12 @@ FirmwarePluginFactoryRegister* FirmwarePluginFactoryRegister::instance(void) @@ -48,6 +49,12 @@ FirmwarePluginFactoryRegister* FirmwarePluginFactoryRegister::instance(void)
return _instance;
}
FirmwarePlugin::FirmwarePlugin(void)
{
qmlRegisterType<RadioComponentController> ("QGroundControl.Controllers", 1, 0, "RadioComponentController");
}
AutoPilotPlugin* FirmwarePlugin::autopilotPlugin(Vehicle* vehicle)
{
return new GenericAutoPilotPlugin(vehicle, vehicle);

2
src/FirmwarePlugin/FirmwarePlugin.h

@ -41,6 +41,8 @@ class FirmwarePlugin : public QObject @@ -41,6 +41,8 @@ class FirmwarePlugin : public QObject
Q_OBJECT
public:
FirmwarePlugin ();
/// Set of optional capabilites which firmware may support
typedef enum {
SetFlightModeCapability = 1 << 0, ///< FirmwarePlugin::setFlightMode method is supported

2
src/QGCApplication.cc

@ -52,7 +52,6 @@ @@ -52,7 +52,6 @@
#include "QGCLoggingCategory.h"
#include "ParameterEditorController.h"
#include "ESP8266ComponentController.h"
#include "RadioComponentController.h"
#include "ScreenToolsController.h"
#include "QGCFileDialogController.h"
#include "RCChannelMonitorController.h"
@ -570,7 +569,6 @@ void QGCApplication::_initCommon() @@ -570,7 +569,6 @@ void QGCApplication::_initCommon()
qmlRegisterType<ParameterEditorController> (kQGCControllers, 1, 0, "ParameterEditorController");
qmlRegisterType<ESP8266ComponentController> (kQGCControllers, 1, 0, "ESP8266ComponentController");
qmlRegisterType<RadioComponentController> (kQGCControllers, 1, 0, "RadioComponentController");
qmlRegisterType<ScreenToolsController> (kQGCControllers, 1, 0, "ScreenToolsController");
qmlRegisterType<PlanMasterController> (kQGCControllers, 1, 0, "PlanMasterController");
qmlRegisterType<QGCFileDialogController> (kQGCControllers, 1, 0, "QGCFileDialogController");

Loading…
Cancel
Save