修改心跳,采用定时器加线程,修改航线保存组别,修改高度显示
This commit is contained in:
@@ -2524,7 +2524,10 @@ void OPMapWidget::WPSave(QString path)//带文件目录参数
|
||||
foreach(QGraphicsItem * i, map->childItems()) {
|
||||
WayPointItem *w = qgraphicsitem_cast<WayPointItem *>(i);
|
||||
if (w) {//逐渐往下增加
|
||||
wlist.insert(w->Number(),w);
|
||||
if(w->MissionType() == currentGroup)
|
||||
{
|
||||
wlist.insert(w->Number(),w);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2963,6 +2966,31 @@ void OPMapWidget::WPGroup(int value)
|
||||
find_PointNumber(currentGroup);
|
||||
|
||||
|
||||
|
||||
QMap<int,float> Info_Elevation;
|
||||
QMap<int,float> Info_Altitude;
|
||||
|
||||
foreach(QGraphicsItem * i, map->childItems()) {
|
||||
WayPointItem *w = qgraphicsitem_cast<WayPointItem *>(i);
|
||||
if (w)
|
||||
{
|
||||
if(w->MissionType() == currentGroup)
|
||||
{
|
||||
if(!w->FollowPrevious())
|
||||
{
|
||||
Info_Elevation.insert(w->Number(),w->getElevation());
|
||||
Info_Altitude.insert(w->Number(),w->Alt());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if(altitudeitem)
|
||||
{
|
||||
altitudeitem->setElevation(Info_Elevation);
|
||||
altitudeitem->setAltitude(Info_Altitude);
|
||||
}
|
||||
|
||||
|
||||
update();
|
||||
}
|
||||
|
||||
@@ -3521,8 +3549,11 @@ void OPMapWidget::ElevationChanged(int seq,double value)
|
||||
WayPointItem *w = qgraphicsitem_cast<WayPointItem *>(i);
|
||||
if (w)
|
||||
{
|
||||
if(!w->FollowPrevious())
|
||||
Info.insert(w->Number(),w->getElevation());
|
||||
if(w->MissionType() == currentGroup)
|
||||
{
|
||||
if(!w->FollowPrevious())
|
||||
Info.insert(w->Number(),w->getElevation());
|
||||
}
|
||||
}
|
||||
}
|
||||
if(altitudeitem)
|
||||
@@ -3539,8 +3570,11 @@ void OPMapWidget::AltitudeChanged(int seq,double value)
|
||||
WayPointItem *w = qgraphicsitem_cast<WayPointItem *>(i);
|
||||
if (w)
|
||||
{
|
||||
if(!w->FollowPrevious())
|
||||
Info.insert(w->Number(),w->Alt());
|
||||
if(w->MissionType() == currentGroup)
|
||||
{
|
||||
if(!w->FollowPrevious())
|
||||
Info.insert(w->Number(),w->Alt());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user