mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-29 14:52:12 +01:00
OP-1150 UI for thermal calibration: put everything inside OpenPilot namespaces
This commit is contained in:
parent
3f5af83d42
commit
eef8bebf15
@ -33,6 +33,7 @@
|
||||
#include <QEventTransition>
|
||||
|
||||
#include "thermalcalibrationhelper.h"
|
||||
namespace OpenPilot {
|
||||
|
||||
class BoardSetupTransition : public QSignalTransition {
|
||||
Q_OBJECT
|
||||
@ -78,6 +79,6 @@ public slots:
|
||||
private:
|
||||
ThermalCalibrationHelper *m_helper;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif // BOARDSETUPTRANSITION_H
|
||||
|
@ -33,6 +33,7 @@
|
||||
#include <QEventTransition>
|
||||
|
||||
#include "thermalcalibrationhelper.h"
|
||||
namespace OpenPilot {
|
||||
|
||||
class DataAcquisitionTransition : public QSignalTransition {
|
||||
Q_OBJECT
|
||||
@ -66,5 +67,6 @@ public slots:
|
||||
private:
|
||||
ThermalCalibrationHelper *m_helper;
|
||||
};
|
||||
}
|
||||
|
||||
#endif // DATAACQUISITIONTRANSITION_H
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include <QEventTransition>
|
||||
|
||||
#include "thermalcalibrationhelper.h"
|
||||
namespace OpenPilot {
|
||||
|
||||
class BoardStatusSaveTransition : public QSignalTransition {
|
||||
Q_OBJECT
|
||||
@ -115,6 +116,6 @@ public slots:
|
||||
private:
|
||||
ThermalCalibrationHelper *m_helper;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif // SETTINGSHANDLINGTRANSITIONS_H
|
||||
|
@ -27,6 +27,7 @@
|
||||
*/
|
||||
#include "thermalcalibrationhelper.h"
|
||||
|
||||
namespace OpenPilot {
|
||||
ThermalCalibrationHelper::ThermalCalibrationHelper(QObject *parent) :
|
||||
QObject(parent)
|
||||
{
|
||||
@ -357,3 +358,4 @@ UAVObjectManager *ThermalCalibrationHelper::getObjectManager()
|
||||
Q_ASSERT(objMngr);
|
||||
return objMngr;
|
||||
}
|
||||
}
|
||||
|
@ -49,6 +49,7 @@
|
||||
#include <accelgyrosettings.h>
|
||||
#include <revocalibration.h>
|
||||
#include <revosettings.h>
|
||||
namespace OpenPilot {
|
||||
|
||||
typedef struct {
|
||||
// this is not needed for revo, but should for CC/CC3D
|
||||
@ -168,5 +169,5 @@ private:
|
||||
void setMetadataForCalibration(UAVDataObject *uavo);
|
||||
UAVObjectManager *getObjectManager();
|
||||
};
|
||||
|
||||
}
|
||||
#endif // THERMALCALIBRATIONHELPER_H
|
||||
|
@ -35,6 +35,7 @@
|
||||
#define NEXT_EVENT "next"
|
||||
#define PREVIOUS_EVENT "previous"
|
||||
#define ABORT_EVENT "abort"
|
||||
namespace OpenPilot {
|
||||
|
||||
ThermalCalibrationModel::ThermalCalibrationModel(QObject *parent) :
|
||||
WizardModel(parent)
|
||||
@ -102,3 +103,4 @@ void ThermalCalibrationModel::setTransitions()
|
||||
m_finalizeState->addTransition(this, SIGNAL(next()), m_readyState);
|
||||
// Ready
|
||||
}
|
||||
}
|
||||
|
@ -37,6 +37,7 @@
|
||||
#include <QStateMachine>
|
||||
#include "../wizardstate.h"
|
||||
#include "../wizardmodel.h"
|
||||
namespace OpenPilot {
|
||||
|
||||
class ThermalCalibrationModel : public WizardModel {
|
||||
Q_PROPERTY(bool startEnable READ startEnabled NOTIFY startEnabledChanged)
|
||||
@ -192,6 +193,6 @@ public slots:
|
||||
emit abort();
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif // THERMALCALIBRATIONMODEL_H
|
||||
|
@ -222,7 +222,7 @@ ConfigRevoWidget::ConfigRevoWidget(QWidget *parent) :
|
||||
autoLoadWidgets();
|
||||
|
||||
// connect the thermalCalibration model to UI
|
||||
m_thermalCalibrationModel = new ThermalCalibrationModel(this);
|
||||
m_thermalCalibrationModel = new OpenPilot::ThermalCalibrationModel(this);
|
||||
|
||||
connect(m_ui->ThermalBiasStart, SIGNAL(clicked()), m_thermalCalibrationModel, SLOT(btnStart()));
|
||||
connect(m_ui->ThermalBiasEnd, SIGNAL(clicked()), m_thermalCalibrationModel, SLOT(btnEnd()));
|
||||
|
@ -57,7 +57,7 @@ private:
|
||||
// ! Computes the scale and bias of the mag based on collected data
|
||||
void computeScaleBias();
|
||||
|
||||
ThermalCalibrationModel *m_thermalCalibrationModel;
|
||||
OpenPilot::ThermalCalibrationModel *m_thermalCalibrationModel;
|
||||
Ui_RevoSensorsWidget *m_ui;
|
||||
QGraphicsSvgItem *paperplane;
|
||||
QGraphicsSvgItem *sensorsBargraph;
|
||||
|
Loading…
x
Reference in New Issue
Block a user