添加了所有的设置界面,设置界面还存在不会隐藏的问题
This commit is contained in:
+258
-45
@@ -75,6 +75,16 @@ propertyui::propertyui(QWidget *parent) :
|
|||||||
_loadMavCmdInfoJson(":/json/MavCmdInfoCommon.json", true);
|
_loadMavCmdInfoJson(":/json/MavCmdInfoCommon.json", true);
|
||||||
//给combox添加items
|
//给combox添加items
|
||||||
|
|
||||||
|
ui->label_Descript->adjustSize();
|
||||||
|
ui->label_Descript->setWordWrap(true);
|
||||||
|
ui->label_Descript->setAlignment(Qt::AlignTop);
|
||||||
|
|
||||||
|
ui->label_Alt_description->adjustSize();
|
||||||
|
ui->label_Alt_description->setWordWrap(true);
|
||||||
|
ui->label_Alt_description->setAlignment(Qt::AlignTop);
|
||||||
|
|
||||||
|
|
||||||
|
ui->comboBox_Frame->addItems(FrameType::TypesList());
|
||||||
|
|
||||||
for(QJsonValue info: MAV_CMD_infoArray) {
|
for(QJsonValue info: MAV_CMD_infoArray) {
|
||||||
if (!info.isObject()) {
|
if (!info.isObject()) {
|
||||||
@@ -84,14 +94,18 @@ propertyui::propertyui(QWidget *parent) :
|
|||||||
ui->comboBox_friendlyName->addItem(info.toObject().value(_friendlyNameJsonKey).toString(),info.toObject().value(_idJsonKey).toInt());
|
ui->comboBox_friendlyName->addItem(info.toObject().value(_friendlyNameJsonKey).toString(),info.toObject().value(_idJsonKey).toInt());
|
||||||
ui->comboBox_MAV_CMD->addItem(info.toObject().value(_rawNameJsonKey).toString(),info.toObject().value(_idJsonKey).toInt());
|
ui->comboBox_MAV_CMD->addItem(info.toObject().value(_rawNameJsonKey).toString(),info.toObject().value(_idJsonKey).toInt());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//建立底部的参数信息
|
//建立底部的参数信息
|
||||||
rebuildUI("Waypoint");
|
rebuildUI("Waypoint");
|
||||||
|
|
||||||
|
|
||||||
|
connect(ui->radioButton_Relative,SIGNAL(clicked(bool)),
|
||||||
|
this,SLOT(on_radioButton_clicked()));
|
||||||
|
connect(ui->radioButton_Absolutely,SIGNAL(clicked(bool)),
|
||||||
|
this,SLOT(on_radioButton_clicked()));
|
||||||
|
connect(ui->radioButton_AGL,SIGNAL(clicked(bool)),
|
||||||
|
this,SLOT(on_radioButton_clicked()));
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -105,6 +119,57 @@ void propertyui::on_comboBox_friendlyName_currentTextChanged(const QString &arg1
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void propertyui::on_comboBox_MAV_CMD_currentIndexChanged(int index)
|
||||||
|
{
|
||||||
|
ui->comboBox_friendlyName->setCurrentIndex(index);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void propertyui::on_comboBox_friendlyName_currentIndexChanged(int index)
|
||||||
|
{
|
||||||
|
ui->comboBox_MAV_CMD->setCurrentIndex(index);
|
||||||
|
}
|
||||||
|
|
||||||
|
void propertyui::on_radioButton_clicked()
|
||||||
|
{
|
||||||
|
FrameType::Types type;
|
||||||
|
if(ui->radioButton_Relative->isChecked())
|
||||||
|
{
|
||||||
|
type = FrameType::MAV_FRAME_GLOBAL_RELATIVE_ALT;
|
||||||
|
}
|
||||||
|
if(ui->radioButton_Absolutely->isChecked())
|
||||||
|
{
|
||||||
|
type = FrameType::MAV_FRAME_GLOBAL;
|
||||||
|
}
|
||||||
|
if(ui->radioButton_AGL->isChecked())
|
||||||
|
{
|
||||||
|
type = FrameType::MAV_FRAME_GLOBAL;
|
||||||
|
}
|
||||||
|
|
||||||
|
ui->comboBox_Frame->setCurrentText(FrameType::StrByType(type));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void propertyui::on_pushButton_ShowAll_clicked()
|
||||||
|
{
|
||||||
|
if(isShowDetails == true)
|
||||||
|
{
|
||||||
|
isShowDetails = false;
|
||||||
|
ui->pushButton_ShowAll->setText("Details");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
isShowDetails = true;
|
||||||
|
ui->pushButton_ShowAll->setText("Hidden");
|
||||||
|
}
|
||||||
|
|
||||||
|
rebuildUI(ui->comboBox_friendlyName->currentText());
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void propertyui::rebuildUI(QString CMD)
|
void propertyui::rebuildUI(QString CMD)
|
||||||
{
|
{
|
||||||
@@ -123,19 +188,42 @@ void propertyui::rebuildUI(QString CMD)
|
|||||||
}
|
}
|
||||||
|
|
||||||
//重新载入UI
|
//重新载入UI
|
||||||
|
ui->label_Descript->setText(description());
|
||||||
|
|
||||||
//ui->frame_Speed->setHidden(true);
|
//隐藏altitude 的描述
|
||||||
//ui->frame_Param->setHidden(true);
|
ui->label_Alt_description->setHidden(true);
|
||||||
|
|
||||||
ui->textBrowser_description->setText(description());
|
|
||||||
|
|
||||||
|
|
||||||
|
//根据showDetails设置显示
|
||||||
//还要根据0,1
|
if(isShowDetails == true)
|
||||||
//QStringList enumStrings (void) const { return _enumStrings; }
|
{
|
||||||
//QVariantList enumValues (void) const { return _enumValues; }
|
ui->comboBox_Frame->setHidden(false);
|
||||||
|
ui->comboBox_MAV_CMD->setHidden(false);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ui->comboBox_Frame->setHidden(true);
|
||||||
|
ui->comboBox_MAV_CMD->setHidden(true);
|
||||||
|
}
|
||||||
|
|
||||||
//一个一个设置
|
//一个一个设置
|
||||||
|
QLayoutItem *item;
|
||||||
|
while((item = ui->frame_Param->layout()->takeAt(0)) != 0){
|
||||||
|
//删除widget
|
||||||
|
if(item->widget()){
|
||||||
|
delete item->widget();
|
||||||
|
//item->widget()->deleteLater();
|
||||||
|
}
|
||||||
|
//删除子布局
|
||||||
|
QLayout *childLayout = item->layout();
|
||||||
|
if(childLayout){
|
||||||
|
//clearLayout(childLayout);
|
||||||
|
}
|
||||||
|
delete item;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
for(QMap<int, MissionCmdParamInfo*>::const_iterator item = _paramInfoMap.begin();item != _paramInfoMap.end();item++)
|
for(QMap<int, MissionCmdParamInfo*>::const_iterator item = _paramInfoMap.begin();item != _paramInfoMap.end();item++)
|
||||||
{
|
{
|
||||||
MissionCmdParamInfo* i = item.value();
|
MissionCmdParamInfo* i = item.value();
|
||||||
@@ -143,48 +231,178 @@ void propertyui::rebuildUI(QString CMD)
|
|||||||
switch(i->param())
|
switch(i->param())
|
||||||
{
|
{
|
||||||
case 1:
|
case 1:
|
||||||
|
{
|
||||||
|
QLabel *Label = new QLabel();
|
||||||
|
Label->setText(i->label());
|
||||||
|
QLabel *Unit = new QLabel();
|
||||||
|
Unit->setText(i->units());
|
||||||
|
|
||||||
ui->label_Param1->setText(i->label());
|
|
||||||
ui->label_Unit_Param1->setText(i->units());
|
|
||||||
if(i->enumStrings().size() != 0)
|
if(i->enumStrings().size() != 0)
|
||||||
{
|
{
|
||||||
|
QComboBox *combox = new QComboBox();
|
||||||
|
combox->addItems(i->enumStrings());
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(combox);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ui->lineEdit_Param1->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
QLineEdit *param = new QLineEdit();
|
||||||
|
param->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
||||||
|
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(param);
|
||||||
|
//ui->frame_Param->layout()->addWidget(Unit);
|
||||||
|
}
|
||||||
|
}break;
|
||||||
|
case 2:
|
||||||
|
{
|
||||||
|
QLabel *Label = new QLabel();
|
||||||
|
Label->setText(i->label());
|
||||||
|
QLabel *Unit = new QLabel();
|
||||||
|
Unit->setText(i->units());
|
||||||
|
|
||||||
|
if(i->enumStrings().size() != 0)
|
||||||
|
{
|
||||||
|
QComboBox *combox = new QComboBox();
|
||||||
|
combox->addItems(i->enumStrings());
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(combox);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QLineEdit *param = new QLineEdit();
|
||||||
|
param->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
||||||
|
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(param);
|
||||||
|
//ui->frame_Param->layout()->addWidget(Unit);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 2:
|
|
||||||
ui->label_Param2->setText(i->label());
|
|
||||||
ui->lineEdit_Param2->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
|
||||||
ui->label_Unit_Param2->setText(i->units());
|
|
||||||
break;
|
|
||||||
case 3:
|
case 3:
|
||||||
ui->label_Param3->setText(i->label());
|
{
|
||||||
ui->lineEdit_Param3->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
QLabel *Label = new QLabel();
|
||||||
ui->label_Unit_Param3->setText(i->units());
|
Label->setText(i->label());
|
||||||
|
QLabel *Unit = new QLabel();
|
||||||
|
Unit->setText(i->units());
|
||||||
|
|
||||||
|
if(i->enumStrings().size() != 0)
|
||||||
|
{
|
||||||
|
QComboBox *combox = new QComboBox();
|
||||||
|
combox->addItems(i->enumStrings());
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(combox);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QLineEdit *param = new QLineEdit();
|
||||||
|
param->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
||||||
|
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(param);
|
||||||
|
//ui->frame_Param->layout()->addWidget(Unit);
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 4:
|
||||||
ui->label_Param4->setText(i->label());
|
{
|
||||||
ui->lineEdit_Param4->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
QLabel *Label = new QLabel();
|
||||||
ui->label_Unit_Param4->setText(i->units());
|
Label->setText(i->label());
|
||||||
|
QLabel *Unit = new QLabel();
|
||||||
|
Unit->setText(i->units());
|
||||||
|
|
||||||
|
if(i->enumStrings().size() != 0)
|
||||||
|
{
|
||||||
|
QComboBox *combox = new QComboBox();
|
||||||
|
combox->addItems(i->enumStrings());
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(combox);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QLineEdit *param = new QLineEdit();
|
||||||
|
param->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
||||||
|
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(param);
|
||||||
|
//ui->frame_Param->layout()->addWidget(Unit);
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case 5:
|
case 5:
|
||||||
ui->label_Param5->setText(i->label());
|
{
|
||||||
ui->lineEdit_Param5->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
QLabel *Label = new QLabel();
|
||||||
ui->label_Unit_Param5->setText(i->units());
|
Label->setText(i->label());
|
||||||
|
QLabel *Unit = new QLabel();
|
||||||
|
Unit->setText(i->units());
|
||||||
|
|
||||||
|
if(i->enumStrings().size() != 0)
|
||||||
|
{
|
||||||
|
QComboBox *combox = new QComboBox();
|
||||||
|
combox->addItems(i->enumStrings());
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(combox);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QLineEdit *param = new QLineEdit();
|
||||||
|
param->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
||||||
|
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(param);
|
||||||
|
//ui->frame_Param->layout()->addWidget(Unit);
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case 6:
|
case 6:
|
||||||
ui->label_Param6->setText(i->label());
|
{
|
||||||
ui->lineEdit_Param6->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
QLabel *Label = new QLabel();
|
||||||
ui->label_Unit_Param6->setText(i->units());
|
Label->setText(i->label());
|
||||||
|
QLabel *Unit = new QLabel();
|
||||||
|
Unit->setText(i->units());
|
||||||
|
|
||||||
|
if(i->enumStrings().size() != 0)
|
||||||
|
{
|
||||||
|
QComboBox *combox = new QComboBox();
|
||||||
|
combox->addItems(i->enumStrings());
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(combox);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QLineEdit *param = new QLineEdit();
|
||||||
|
param->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
||||||
|
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(param);
|
||||||
|
//ui->frame_Param->layout()->addWidget(Unit);
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case 7:
|
case 7:
|
||||||
ui->label_Param7->setText(i->label());
|
{
|
||||||
ui->lineEdit_Param7->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
QLabel *Label = new QLabel();
|
||||||
ui->label_Unit_Param7->setText(i->units());
|
Label->setText(i->label());
|
||||||
|
QLabel *Unit = new QLabel();
|
||||||
|
Unit->setText(i->units());
|
||||||
|
|
||||||
|
if(i->enumStrings().size() != 0)
|
||||||
|
{
|
||||||
|
QComboBox *combox = new QComboBox();
|
||||||
|
combox->addItems(i->enumStrings());
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(combox);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QLineEdit *param = new QLineEdit();
|
||||||
|
param->setText(QString::number(i->defaultValue(),'f',i->decimalPlaces()));
|
||||||
|
|
||||||
|
ui->frame_Param->layout()->addWidget(Label);
|
||||||
|
ui->frame_Param->layout()->addWidget(param);
|
||||||
|
//ui->frame_Param->layout()->addWidget(Unit);
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -254,10 +472,6 @@ void propertyui::_loadMavCmdInfoJson(const QString& jsonFilename, bool baseComma
|
|||||||
qWarning() << jsonFilename << "mavCmdArray should contain objects";
|
qWarning() << jsonFilename << "mavCmdArray should contain objects";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
//QString str;
|
|
||||||
//loadJsonInfo(info.toObject(),true,str);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -449,9 +663,6 @@ bool propertyui::loadJsonInfo(const QJsonObject& jsonObject, bool requireFullObj
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//qDebug() << _infoMap;
|
|
||||||
|
|
||||||
if (requireFullObject) {
|
if (requireFullObject) {
|
||||||
// Since this is the base of the hierarchy it must contain valid defaults for all values.
|
// Since this is the base of the hierarchy it must contain valid defaults for all values.
|
||||||
if (!_infoAvailable(_categoryJsonKey)) {
|
if (!_infoAvailable(_categoryJsonKey)) {
|
||||||
@@ -491,10 +702,8 @@ bool propertyui::loadJsonInfo(const QJsonObject& jsonObject, bool requireFullObj
|
|||||||
for (const QString& infoKey: _infoMap.keys()) {
|
for (const QString& infoKey: _infoMap.keys()) {
|
||||||
debugOutput.append(QString("MavCmdInfo %1: %2 ").arg(infoKey).arg(_infoMap[infoKey].toString()));
|
debugOutput.append(QString("MavCmdInfo %1: %2 ").arg(infoKey).arg(_infoMap[infoKey].toString()));
|
||||||
}
|
}
|
||||||
qDebug() << debugOutput;
|
|
||||||
|
|
||||||
// Read params
|
// Read params
|
||||||
|
|
||||||
for (int i=1; i<=7; i++) {
|
for (int i=1; i<=7; i++) {
|
||||||
QString paramKey = QString(_paramJsonKeyFormat).arg(i);
|
QString paramKey = QString(_paramJsonKeyFormat).arg(i);
|
||||||
|
|
||||||
@@ -594,3 +803,7 @@ bool propertyui::loadJsonInfo(const QJsonObject& jsonObject, bool requireFullObj
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -25,6 +25,18 @@
|
|||||||
#include "JsonHelper.h"
|
#include "JsonHelper.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#include "QComboBox"
|
||||||
|
#include "QLineEdit"
|
||||||
|
#include "QLabel"
|
||||||
|
#include "QHBoxLayout"
|
||||||
|
#include "QVBoxLayout"
|
||||||
|
#include "QGridLayout"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef QtopmapWidget
|
#ifdef QtopmapWidget
|
||||||
#include <mapwidgetglobal.h>
|
#include <mapwidgetglobal.h>
|
||||||
namespace Ui {
|
namespace Ui {
|
||||||
@@ -75,9 +87,68 @@ private:
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef QtopmapWidget
|
||||||
|
#include <mapwidgetglobal.h>
|
||||||
|
class OPMAPWIDGETSHARED_EXPORT FrameType : public QObject {
|
||||||
|
#else
|
||||||
|
class FrameType : public QObject {
|
||||||
|
#endif
|
||||||
|
Q_OBJECT Q_ENUMS(Types)
|
||||||
|
public:
|
||||||
|
enum Types {
|
||||||
|
MAV_FRAME_GLOBAL=0, /* Global coordinate frame, WGS84 coordinate system. First value / x: latitude, second value / y: longitude, third value / z: positive altitude over mean sea level (MSL). | */
|
||||||
|
MAV_FRAME_LOCAL_NED=1, /* Local coordinate frame, Z-down (x: north, y: east, z: down). | */
|
||||||
|
MAV_FRAME_MISSION=2, /* NOT a coordinate frame, indicates a mission command. | */
|
||||||
|
MAV_FRAME_GLOBAL_RELATIVE_ALT=3, /* Global coordinate frame, WGS84 coordinate system, relative altitude over ground with respect to the home position. First value / x: latitude, second value / y: longitude, third value / z: positive altitude with 0 being at the altitude of the home location. | */
|
||||||
|
MAV_FRAME_LOCAL_ENU=4, /* Local coordinate frame, Z-up (x: east, y: north, z: up). | */
|
||||||
|
MAV_FRAME_GLOBAL_INT=5, /* Global coordinate frame, WGS84 coordinate system. First value / x: latitude in degrees*1.0e-7, second value / y: longitude in degrees*1.0e-7, third value / z: positive altitude over mean sea level (MSL). | */
|
||||||
|
MAV_FRAME_GLOBAL_RELATIVE_ALT_INT=6, /* Global coordinate frame, WGS84 coordinate system, relative altitude over ground with respect to the home position. First value / x: latitude in degrees*10e-7, second value / y: longitude in degrees*10e-7, third value / z: positive altitude with 0 being at the altitude of the home location. | */
|
||||||
|
MAV_FRAME_LOCAL_OFFSET_NED=7, /* Offset to the current local frame. Anything expressed in this frame should be added to the current local frame position. | */
|
||||||
|
MAV_FRAME_BODY_NED=8, /* Setpoint in body NED frame. This makes sense if all position control is externalized - e.g. useful to command 2 m/s^2 acceleration to the right. | */
|
||||||
|
MAV_FRAME_BODY_OFFSET_NED=9, /* Offset in body NED frame. This makes sense if adding setpoints to the current flight path, to avoid an obstacle - e.g. useful to command 2 m/s^2 acceleration to the east. | */
|
||||||
|
MAV_FRAME_GLOBAL_TERRAIN_ALT=10, /* Global (WGS84) coordinate frame with AGL altitude (at the waypoint coordinate). First value / x: latitude in degrees, second value / y: longitude in degrees, third value / z: positive altitude in meters with 0 being at ground level in terrain model. | */
|
||||||
|
MAV_FRAME_GLOBAL_TERRAIN_ALT_INT=11, /* Global (WGS84) coordinate frame with AGL altitude (at the waypoint coordinate). First value / x: latitude in degrees*10e-7, second value / y: longitude in degrees*10e-7, third value / z: positive altitude in meters with 0 being at ground level in terrain model. | */
|
||||||
|
MAV_FRAME_BODY_FRD=12, /* Body fixed frame of reference, Z-down (x: forward, y: right, z: down). | */
|
||||||
|
MAV_FRAME_BODY_FLU=13, /* Body fixed frame of reference, Z-up (x: forward, y: left, z: up). | */
|
||||||
|
MAV_FRAME_MOCAP_NED=14, /* Odometry local coordinate frame of data given by a motion capture system, Z-down (x: north, y: east, z: down). | */
|
||||||
|
MAV_FRAME_MOCAP_ENU=15, /* Odometry local coordinate frame of data given by a motion capture system, Z-up (x: east, y: north, z: up). | */
|
||||||
|
MAV_FRAME_VISION_NED=16, /* Odometry local coordinate frame of data given by a vision estimation system, Z-down (x: north, y: east, z: down). | */
|
||||||
|
MAV_FRAME_VISION_ENU=17, /* Odometry local coordinate frame of data given by a vision estimation system, Z-up (x: east, y: north, z: up). | */
|
||||||
|
MAV_FRAME_ESTIM_NED=18, /* Odometry local coordinate frame of data given by an estimator running onboard the vehicle, Z-down (x: north, y: east, z: down). | */
|
||||||
|
MAV_FRAME_ESTIM_ENU=19, /* Odometry local coordinate frame of data given by an estimator running onboard the vehicle, Z-up (x: east, y: noth, z: up). | */
|
||||||
|
MAV_FRAME_ENUM_END=20, /* | */
|
||||||
|
};
|
||||||
|
static QString StrByType(Types const & value)
|
||||||
|
{
|
||||||
|
QMetaObject metaObject = FrameType().staticMetaObject;
|
||||||
|
QMetaEnum metaEnum = metaObject.enumerator(metaObject.indexOfEnumerator("Types"));
|
||||||
|
QString s = metaEnum.valueToKey(value);
|
||||||
|
|
||||||
|
return s;
|
||||||
|
}
|
||||||
|
static Types TypeByStr(QString const & value)
|
||||||
|
{
|
||||||
|
QMetaObject metaObject = FrameType().staticMetaObject;
|
||||||
|
QMetaEnum metaEnum = metaObject.enumerator(metaObject.indexOfEnumerator("Types"));
|
||||||
|
Types s = (Types)metaEnum.keyToValue(value.toLatin1());
|
||||||
|
|
||||||
|
return s;
|
||||||
|
}
|
||||||
|
static QStringList TypesList()
|
||||||
|
{
|
||||||
|
QStringList ret;
|
||||||
|
QMetaObject metaObject = FrameType().staticMetaObject;
|
||||||
|
QMetaEnum metaEnum = metaObject.enumerator(metaObject.indexOfEnumerator("Types"));
|
||||||
|
|
||||||
|
for (int x = 0; x < metaEnum.keyCount(); ++x) {
|
||||||
|
ret.append(metaEnum.key(x));
|
||||||
|
}
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
friend class propertyui;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -112,9 +183,6 @@ public:
|
|||||||
~propertyui();
|
~propertyui();
|
||||||
|
|
||||||
|
|
||||||
Q_ENUM(MAV_FRAME)
|
|
||||||
|
|
||||||
|
|
||||||
Q_PROPERTY(QString category READ category CONSTANT)
|
Q_PROPERTY(QString category READ category CONSTANT)
|
||||||
Q_PROPERTY(QString description READ description CONSTANT)
|
Q_PROPERTY(QString description READ description CONSTANT)
|
||||||
Q_PROPERTY(bool friendlyEdit READ friendlyEdit CONSTANT)
|
Q_PROPERTY(bool friendlyEdit READ friendlyEdit CONSTANT)
|
||||||
@@ -149,6 +217,13 @@ public:
|
|||||||
private slots:
|
private slots:
|
||||||
|
|
||||||
void on_comboBox_friendlyName_currentTextChanged(const QString &arg1);
|
void on_comboBox_friendlyName_currentTextChanged(const QString &arg1);
|
||||||
|
void on_comboBox_MAV_CMD_currentIndexChanged(int index);
|
||||||
|
|
||||||
|
void on_comboBox_friendlyName_currentIndexChanged(int index);
|
||||||
|
|
||||||
|
void on_radioButton_clicked();
|
||||||
|
|
||||||
|
void on_pushButton_ShowAll_clicked();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QString _loadErrorString(const QString& errorString) const;
|
QString _loadErrorString(const QString& errorString) const;
|
||||||
@@ -204,6 +279,8 @@ private:
|
|||||||
QJsonArray MAV_CMD_infoArray;
|
QJsonArray MAV_CMD_infoArray;
|
||||||
|
|
||||||
|
|
||||||
|
bool isShowDetails = false;
|
||||||
|
|
||||||
|
|
||||||
//QQuickWidget *property_quick = nullptr;
|
//QQuickWidget *property_quick = nullptr;
|
||||||
|
|
||||||
|
|||||||
+221
-223
@@ -6,26 +6,16 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>356</width>
|
<width>231</width>
|
||||||
<height>524</height>
|
<height>452</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Form</string>
|
<string>Form</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
<layout class="QGridLayout" name="gridLayout_4">
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
<item>
|
|
||||||
<widget class="QLabel" name="label_Seq">
|
|
||||||
<property name="text">
|
|
||||||
<string>Seq</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QComboBox" name="comboBox_friendlyName"/>
|
|
||||||
</item>
|
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_Last">
|
<widget class="QPushButton" name="pushButton_Last">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
@@ -40,214 +30,9 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButton_ShowAll">
|
|
||||||
<property name="text">
|
|
||||||
<string>Show</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QTextBrowser" name="textBrowser_description">
|
|
||||||
<property name="html">
|
|
||||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
|
||||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
|
||||||
p, li { white-space: pre-wrap; }
|
|
||||||
</style></head><body style=" font-family:'SimSun'; font-size:9pt; font-weight:400; font-style:normal;">
|
|
||||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'SimSun';">kjhvbkuviuyvyvtuytvuytvihyubgiurcddddddddchhytrfcjhcviytciytcdiuytfbniyrdu6erdbtr</span></p></body></html></string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="0">
|
|
||||||
<widget class="QFrame" name="frame_Alt">
|
|
||||||
<property name="frameShape">
|
|
||||||
<enum>QFrame::StyledPanel</enum>
|
|
||||||
</property>
|
|
||||||
<property name="frameShadow">
|
|
||||||
<enum>QFrame::Raised</enum>
|
|
||||||
</property>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_10">
|
|
||||||
<item>
|
|
||||||
<widget class="QRadioButton" name="radioButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>Relative</string>
|
|
||||||
</property>
|
|
||||||
<property name="checked">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QRadioButton" name="radioButton_2">
|
|
||||||
<property name="text">
|
|
||||||
<string>Absolutely</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QRadioButton" name="radioButton_3">
|
|
||||||
<property name="text">
|
|
||||||
<string>AGL</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Alt"/>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QLabel" name="label_Alt_description">
|
|
||||||
<property name="text">
|
|
||||||
<string>TextLabel</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QComboBox" name="comboBox_MAV_CMD"/>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QComboBox" name="comboBox_Frame"/>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="0">
|
|
||||||
<widget class="QFrame" name="frame_Param">
|
|
||||||
<property name="frameShape">
|
|
||||||
<enum>QFrame::StyledPanel</enum>
|
|
||||||
</property>
|
|
||||||
<property name="frameShadow">
|
|
||||||
<enum>QFrame::Raised</enum>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout_3">
|
|
||||||
<item row="0" column="0">
|
|
||||||
<widget class="QLabel" name="label_Param1">
|
|
||||||
<property name="text">
|
|
||||||
<string>Param1</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Param1"/>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="2">
|
|
||||||
<widget class="QLabel" name="label_Unit_Param1">
|
|
||||||
<property name="text">
|
|
||||||
<string>Unit</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QLabel" name="label_Param2">
|
|
||||||
<property name="text">
|
|
||||||
<string>Param2</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Param2"/>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="2">
|
|
||||||
<widget class="QLabel" name="label_Unit_Param2">
|
|
||||||
<property name="text">
|
|
||||||
<string>Unit</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="0">
|
|
||||||
<widget class="QLabel" name="label_Param3">
|
|
||||||
<property name="text">
|
|
||||||
<string>Param3</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Param3"/>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="2">
|
|
||||||
<widget class="QLabel" name="label_Unit_Param3">
|
|
||||||
<property name="text">
|
|
||||||
<string>Unit</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="0">
|
|
||||||
<widget class="QLabel" name="label_Param4">
|
|
||||||
<property name="text">
|
|
||||||
<string>Param4</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Param4"/>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="2">
|
|
||||||
<widget class="QLabel" name="label_Unit_Param4">
|
|
||||||
<property name="text">
|
|
||||||
<string>Unit</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="0">
|
|
||||||
<widget class="QLabel" name="label_Param5">
|
|
||||||
<property name="text">
|
|
||||||
<string>Lat/X</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Param5"/>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="2">
|
|
||||||
<widget class="QLabel" name="label_Unit_Param5">
|
|
||||||
<property name="text">
|
|
||||||
<string>Unit</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="0">
|
|
||||||
<widget class="QLabel" name="label_Param6">
|
|
||||||
<property name="text">
|
|
||||||
<string>Lng/Y</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Param6"/>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="2">
|
|
||||||
<widget class="QLabel" name="label_Unit_Param6">
|
|
||||||
<property name="text">
|
|
||||||
<string>Unit</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="6" column="0">
|
<item row="6" column="0">
|
||||||
<widget class="QLabel" name="label_Param7">
|
|
||||||
<property name="text">
|
|
||||||
<string>Alt/Z</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="6" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Param7"/>
|
|
||||||
</item>
|
|
||||||
<item row="6" column="2">
|
|
||||||
<widget class="QLabel" name="label_Unit_Param7">
|
|
||||||
<property name="text">
|
|
||||||
<string>Unit</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="0">
|
|
||||||
<widget class="QFrame" name="frame_Speed">
|
<widget class="QFrame" name="frame_Speed">
|
||||||
<property name="frameShape">
|
<property name="frameShape">
|
||||||
<enum>QFrame::StyledPanel</enum>
|
<enum>QFrame::StyledPanel</enum>
|
||||||
@@ -256,6 +41,18 @@ p, li { white-space: pre-wrap; }
|
|||||||
<enum>QFrame::Raised</enum>
|
<enum>QFrame::Raised</enum>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_9">
|
<layout class="QHBoxLayout" name="horizontalLayout_9">
|
||||||
<item>
|
<item>
|
||||||
@@ -284,6 +81,191 @@ p, li { white-space: pre-wrap; }
|
|||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="5" column="0">
|
||||||
|
<widget class="QFrame" name="frame_Param">
|
||||||
|
<property name="frameShape">
|
||||||
|
<enum>QFrame::StyledPanel</enum>
|
||||||
|
</property>
|
||||||
|
<property name="frameShadow">
|
||||||
|
<enum>QFrame::Raised</enum>
|
||||||
|
</property>
|
||||||
|
<layout class="QGridLayout" name="gridLayout_3">
|
||||||
|
<item row="3" column="0">
|
||||||
|
<widget class="QLabel" name="label_Param4">
|
||||||
|
<property name="text">
|
||||||
|
<string>Param4</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="3" column="1">
|
||||||
|
<widget class="QLineEdit" name="lineEdit_Param4"/>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QLabel" name="label_Param2">
|
||||||
|
<property name="text">
|
||||||
|
<string>Param2</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QLineEdit" name="lineEdit_Param1"/>
|
||||||
|
</item>
|
||||||
|
<item row="4" column="0">
|
||||||
|
<widget class="QLabel" name="label_Param5">
|
||||||
|
<property name="text">
|
||||||
|
<string>Lat/X</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="5" column="1">
|
||||||
|
<widget class="QLineEdit" name="lineEdit_Param6"/>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="1">
|
||||||
|
<widget class="QLineEdit" name="lineEdit_Param3"/>
|
||||||
|
</item>
|
||||||
|
<item row="6" column="0">
|
||||||
|
<widget class="QLabel" name="label_Param7">
|
||||||
|
<property name="text">
|
||||||
|
<string>Alt/Z</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="6" column="1">
|
||||||
|
<widget class="QLineEdit" name="lineEdit_Param7"/>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLabel" name="label_Param1">
|
||||||
|
<property name="text">
|
||||||
|
<string>Param1</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="4" column="1">
|
||||||
|
<widget class="QLineEdit" name="lineEdit_Param5"/>
|
||||||
|
</item>
|
||||||
|
<item row="5" column="0">
|
||||||
|
<widget class="QLabel" name="label_Param6">
|
||||||
|
<property name="text">
|
||||||
|
<string>Lng/Y</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
|
<widget class="QLabel" name="label_Param3">
|
||||||
|
<property name="text">
|
||||||
|
<string>Param3</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="1">
|
||||||
|
<widget class="QLineEdit" name="lineEdit_Param2"/>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
|
<widget class="QLabel" name="label_Descript">
|
||||||
|
<property name="text">
|
||||||
|
<string>TextLabel</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="3" column="0">
|
||||||
|
<layout class="QGridLayout" name="gridLayout_2">
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QComboBox" name="comboBox_MAV_CMD"/>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QComboBox" name="comboBox_Frame"/>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item row="4" column="0">
|
||||||
|
<widget class="QFrame" name="frame_Alt">
|
||||||
|
<property name="frameShape">
|
||||||
|
<enum>QFrame::StyledPanel</enum>
|
||||||
|
</property>
|
||||||
|
<property name="frameShadow">
|
||||||
|
<enum>QFrame::Raised</enum>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_10">
|
||||||
|
<item>
|
||||||
|
<widget class="QRadioButton" name="radioButton_Relative">
|
||||||
|
<property name="text">
|
||||||
|
<string>Relative</string>
|
||||||
|
</property>
|
||||||
|
<property name="checked">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QRadioButton" name="radioButton_Absolutely">
|
||||||
|
<property name="text">
|
||||||
|
<string>Absolutely</string>
|
||||||
|
</property>
|
||||||
|
<property name="checked">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QRadioButton" name="radioButton_AGL">
|
||||||
|
<property name="text">
|
||||||
|
<string>AGL</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLineEdit" name="lineEdit_Alt"/>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_Alt_description">
|
||||||
|
<property name="text">
|
||||||
|
<string>TextLabel</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_Seq">
|
||||||
|
<property name="text">
|
||||||
|
<string>Seq</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QComboBox" name="comboBox_friendlyName"/>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_ShowAll">
|
||||||
|
<property name="text">
|
||||||
|
<string>Details</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
<resources/>
|
<resources/>
|
||||||
@@ -295,12 +277,28 @@ p, li { white-space: pre-wrap; }
|
|||||||
<slot>setEnabled(bool)</slot>
|
<slot>setEnabled(bool)</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>44</x>
|
<x>48</x>
|
||||||
<y>491</y>
|
<y>464</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>115</x>
|
<x>186</x>
|
||||||
<y>495</y>
|
<y>466</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
|
<connection>
|
||||||
|
<sender>lineEdit_Param7</sender>
|
||||||
|
<signal>textChanged(QString)</signal>
|
||||||
|
<receiver>lineEdit_Alt</receiver>
|
||||||
|
<slot>setText(QString)</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>60</x>
|
||||||
|
<y>437</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>23</x>
|
||||||
|
<y>241</y>
|
||||||
</hint>
|
</hint>
|
||||||
</hints>
|
</hints>
|
||||||
</connection>
|
</connection>
|
||||||
|
|||||||
@@ -462,6 +462,7 @@ void WayPointItem::SetDefault(double lat,double lng,float alt,uint16_t seq)
|
|||||||
property.z = alt;
|
property.z = alt;
|
||||||
property.seq = seq;
|
property.seq = seq;
|
||||||
property.command = MAV_CMD::MAV_CMD_NAV_WAYPOINT;
|
property.command = MAV_CMD::MAV_CMD_NAV_WAYPOINT;
|
||||||
|
property.frame = MAV_FRAME::MAV_FRAME_GLOBAL;
|
||||||
//...
|
//...
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user