mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-02-21 11:54:15 +01:00
Make the outputs test function disable when the connection is lost.
This commit is contained in:
parent
856f8a9b6c
commit
2b94a1538b
@ -170,6 +170,13 @@ ConfigOutputWidget::ConfigOutputWidget(QWidget *parent) : ConfigTaskWidget(paren
|
|||||||
this->setEnabled(false);
|
this->setEnabled(false);
|
||||||
connect(obj,SIGNAL(objectUpdated(UAVObject*)),this,SLOT(disableIfNotMe(UAVObject*)));
|
connect(obj,SIGNAL(objectUpdated(UAVObject*)),this,SLOT(disableIfNotMe(UAVObject*)));
|
||||||
}
|
}
|
||||||
|
void ConfigOutputWidget::enableControls(bool enable)
|
||||||
|
{
|
||||||
|
ConfigTaskWidget::enableControls(enable);
|
||||||
|
if(!enable)
|
||||||
|
m_config->channelOutTest->setChecked(false);
|
||||||
|
m_config->channelOutTest->setEnabled(enable);
|
||||||
|
}
|
||||||
|
|
||||||
ConfigOutputWidget::~ConfigOutputWidget()
|
ConfigOutputWidget::~ConfigOutputWidget()
|
||||||
{
|
{
|
||||||
@ -216,6 +223,7 @@ void ConfigOutputWidget::linkToggled(bool state)
|
|||||||
*/
|
*/
|
||||||
void ConfigOutputWidget::runChannelTests(bool state)
|
void ConfigOutputWidget::runChannelTests(bool state)
|
||||||
{
|
{
|
||||||
|
qDebug()<<"configoutputwidget runChannelTests"<<state;
|
||||||
SystemAlarms * systemAlarmsObj = SystemAlarms::GetInstance(getObjectManager());
|
SystemAlarms * systemAlarmsObj = SystemAlarms::GetInstance(getObjectManager());
|
||||||
SystemAlarms::DataFields systemAlarms = systemAlarmsObj->getData();
|
SystemAlarms::DataFields systemAlarms = systemAlarmsObj->getData();
|
||||||
|
|
||||||
|
@ -46,6 +46,7 @@ public:
|
|||||||
ConfigOutputWidget(QWidget *parent = 0);
|
ConfigOutputWidget(QWidget *parent = 0);
|
||||||
~ConfigOutputWidget();
|
~ConfigOutputWidget();
|
||||||
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Ui_OutputWidget *m_config;
|
Ui_OutputWidget *m_config;
|
||||||
|
|
||||||
@ -82,6 +83,8 @@ private slots:
|
|||||||
void linkToggled(bool state);
|
void linkToggled(bool state);
|
||||||
void setSpinningArmed(bool val);
|
void setSpinningArmed(bool val);
|
||||||
void openHelp();
|
void openHelp();
|
||||||
|
protected:
|
||||||
|
void enableControls(bool enable);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user