diff --git a/App/MissionUI/propertyui.cpp b/App/MissionUI/propertyui.cpp index 27212e3..3a80b68 100644 --- a/App/MissionUI/propertyui.cpp +++ b/App/MissionUI/propertyui.cpp @@ -87,7 +87,7 @@ propertyui::propertyui(QWidget *parent) : this->adjustSize(); //初始化参数 - setWayPointProperty(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); + setWayPointProperty(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3); //初始化ui //一个一个设置 @@ -116,8 +116,8 @@ propertyui::propertyui(QWidget *parent) : //ui->pushButton_2->hide(); ui->pushButton_Group->setText("1"); - m_mission_type = 3; - emit WPGroup(m_mission_type); + missionGroups = 3; + emit WPGroup(missionGroups); //载入json @@ -193,8 +193,6 @@ void propertyui::rebuildUI(QString CMD) //重新载入UI - //ui->pushButton_Group->setText(QString::number(m_mission_type - 2)); - ui->pushButton_Seq->setText(QString::number(m_seq)); ui->label_Descript->setText(description()); @@ -773,13 +771,20 @@ void propertyui::WayPointPropertyUpdate(bool flag) << m_frame << m_current << m_autocontinue - << m_mission_type ; - + << missionGroups; + //<< m_mission_type ; +/* emit WayPointPropertyChanged(m_param1,m_param2,m_param3,m_param4, m_x,m_y,m_z, m_seq,m_group,m_command, m_target_system,m_target_component, m_frame,m_current,m_autocontinue,m_mission_type); + */ + emit WayPointPropertyChanged(m_param1,m_param2,m_param3,m_param4, + m_x,m_y,m_z, + m_seq,m_group,m_command, + m_target_system,m_target_component, + m_frame,m_current,m_autocontinue,missionGroups); } void propertyui::setWayPointProperty(float param1,float param2,float param3,float param4, @@ -809,7 +814,7 @@ void propertyui::setWayPointProperty(float param1,float param2,float param3,floa m_frame = frame; m_current = current; m_autocontinue = autocontinue; - m_mission_type = mission_type; + missionGroups = mission_type; for(QJsonValue info: MAV_CMD_infoArray) { if (!info.isObject()) { @@ -838,7 +843,7 @@ void propertyui::setWayPointProperty(float param1,float param2,float param3,floa << m_frame << m_current << m_autocontinue - << m_mission_type ; + << missionGroups ; } diff --git a/MavCmdInfoCommon.json b/MavCmdInfoCommon.json index 382875d..1e14282 100644 --- a/MavCmdInfoCommon.json +++ b/MavCmdInfoCommon.json @@ -34,7 +34,7 @@ "param4": { "label": "速度", "units": "m/s", - "default": 0, + "default": 150, "decimalPlaces": 0 } }, @@ -57,7 +57,7 @@ "param1": { "label": "中止高度", "units": "m", - "default": 0, + "default": 1500, "decimalPlaces": 2 }, "param2": { diff --git a/bin/MavCmdInfoCommon.json b/bin/MavCmdInfoCommon.json index 382875d..1e14282 100644 --- a/bin/MavCmdInfoCommon.json +++ b/bin/MavCmdInfoCommon.json @@ -34,7 +34,7 @@ "param4": { "label": "速度", "units": "m/s", - "default": 0, + "default": 150, "decimalPlaces": 0 } }, @@ -57,7 +57,7 @@ "param1": { "label": "中止高度", "units": "m", - "default": 0, + "default": 1500, "decimalPlaces": 2 }, "param2": { diff --git a/bin/include/debugheader.h b/bin/include/debugheader.h index d4590fb..7062371 100644 --- a/bin/include/debugheader.h +++ b/bin/include/debugheader.h @@ -1,13 +1,8 @@ #ifndef DEBUGHEADER_H #define DEBUGHEADER_H -// #define DEBUG_MEMORY_CACHE -// #define DEBUG_CACHE -// #define DEBUG_GMAPS -// #define DEBUG_PUREIMAGECACHE -// #define DEBUG_TILECACHEQUEUE -// #define DEBUG_URLFACTORY -// #define DEBUG_MEMORY_CACHE -// #define DEBUG_GetGeocoderFromCache +// #define DEBUG_CORE +// #define DEBUG_TILE +// #define DEBUG_TILEMATRIX #endif // DEBUGHEADER_H diff --git a/bin/include/mathdefine.h b/bin/include/mathdefine.h index 2bdb6f8..d2b41f5 100644 --- a/bin/include/mathdefine.h +++ b/bin/include/mathdefine.h @@ -6,6 +6,13 @@ #ifdef _USE_MATH_DEFINES +#ifdef unix + +#else +#ifdef __MINGW32__ + +#else + #define M_E 2.71828182845904523536 #define M_LOG2E 1.44269504088896340736 #define M_LOG10E 0.434294481903251827651 @@ -19,7 +26,11 @@ #define M_2_SQRTPI 1.12837916709551257390 #define M_SQRT2 1.41421356237309504880 #define M_SQRT1_2 0.707106781186547524401 - +#endif /* __MINGW32__ */ +#endif + + + #endif /* _USE_MATH_DEFINES */ #endif /* END FILE */ diff --git a/bin/maps/Data.qmdb b/bin/maps/Data.qmdb index 8f619e3..e050041 100644 Binary files a/bin/maps/Data.qmdb and b/bin/maps/Data.qmdb differ diff --git a/opmap/mapwidget/waypointitem.cpp b/opmap/mapwidget/waypointitem.cpp index 1d2459d..0c0d3cc 100644 --- a/opmap/mapwidget/waypointitem.cpp +++ b/opmap/mapwidget/waypointitem.cpp @@ -783,6 +783,8 @@ void WayPointItem::SetDefault(double lat,double lng,float alt,uint16_t seq) property.autocontinue = true; property.mission_type = 3; + qDebug() << "waypoint item set default" << property.mission_type; + if(property.command > MAV_CMD::MAV_CMD_NAV_LAST) { qDebug() << "is cmd point";