Unverified Commit aeae385a authored by Don Gagne's avatar Don Gagne Committed by GitHub

Merge pull request #6677 from DonLakeFlyer/TerrainPathQuery

Fix: Terrain path query
parents a27bf5cb ab2f8c6b
......@@ -412,7 +412,7 @@ void TransectStyleComplexItem::_reallyQueryTransectsPathHeightInfo(void)
if (transectPoints.count() > 1) {
_terrainPolyPathQuery = new TerrainPolyPathQuery(this);
connect(_terrainPolyPathQuery, &TerrainPolyPathQuery::terrainData, this, &TransectStyleComplexItem::_polyPathTerrainData);
connect(_terrainPolyPathQuery, &TerrainPolyPathQuery::terrainDataReceived, this, &TransectStyleComplexItem::_polyPathTerrainData);
_terrainPolyPathQuery->requestData(transectPoints);
}
}
......
......@@ -186,7 +186,7 @@ void VisualMissionItem::_reallyUpdateTerrainAltitude(void)
_lastLatTerrainQuery = coord.latitude();
_lastLonTerrainQuery = coord.longitude();
TerrainAtCoordinateQuery* terrain = new TerrainAtCoordinateQuery(this);
connect(terrain, &TerrainAtCoordinateQuery::terrainData, this, &VisualMissionItem::_terrainDataReceived);
connect(terrain, &TerrainAtCoordinateQuery::terrainDataReceived, this, &VisualMissionItem::_terrainDataReceived);
QList<QGeoCoordinate> rgCoord;
rgCoord.append(coordinate());
terrain->requestData(rgCoord);
......
......@@ -43,8 +43,22 @@ QGCView {
id: categoryColumn
spacing: ScreenTools.defaultFontPixelHeight / 2
QGCButton {
text: qsTr("Clear All")
onClicked: {
var logCats = QGroundControl.loggingCategories()
for (var i=0; i<logCats.length; i++) {
QGroundControl.setCategoryLoggingOn(logCats[i], false)
}
QGroundControl.updateLoggingFilterRules()
categoryRepeater.model = undefined
categoryRepeater.model = QGroundControl.loggingCategories()
}
}
Repeater {
model: QGroundControl.loggingCategories()
id: categoryRepeater
model: QGroundControl.loggingCategories()
QGCCheckBox {
text: modelData
......
This diff is collapsed.
......@@ -50,9 +50,9 @@ public:
virtual void requestCarpetHeights(const QGeoCoordinate& swCoord, const QGeoCoordinate& neCoord, bool statsOnly) = 0;
signals:
void coordinateHeights(bool success, QList<double> heights);
void pathHeights(bool success, double latStep, double lonStep, const QList<double>& heights);
void carpetHeights(bool success, double minHeight, double maxHeight, const QList<QList<double>>& carpet);
void coordinateHeightsReceived(bool success, QList<double> heights);
void pathHeightsReceived(bool success, double latStep, double lonStep, const QList<double>& heights);
void carpetHeightsReceived(bool success, double minHeight, double maxHeight, const QList<QList<double>>& carpet);
};
/// AirMap online implementation of terrain queries
......@@ -136,6 +136,7 @@ private:
typedef struct {
TerrainOfflineAirMapQuery* terrainQueryInterface;
QueryMode queryMode;
double latStep, lonStep;
QList<QGeoCoordinate> coordinates;
} QueuedRequestInfo_t;
......@@ -210,7 +211,7 @@ public:
void _signalTerrainData(bool success, QList<double>& heights);
signals:
void terrainData(bool success, QList<double> heights);
void terrainDataReceived(bool success, QList<double> heights);
};
class TerrainPathQuery : public QObject
......@@ -233,7 +234,7 @@ public:
signals:
/// Signalled when terrain data comes back from server
void terrainData(bool success, const PathHeightInfo_t& pathHeightInfo);
void terrainDataReceived(bool success, const PathHeightInfo_t& pathHeightInfo);
private slots:
void _pathHeights(bool success, double latStep, double lonStep, const QList<double>& heights);
......@@ -259,7 +260,7 @@ public:
signals:
/// Signalled when terrain data comes back from server
void terrainData(bool success, const QList<TerrainPathQuery::PathHeightInfo_t>& rgPathHeightInfo);
void terrainDataReceived(bool success, const QList<TerrainPathQuery::PathHeightInfo_t>& rgPathHeightInfo);
private slots:
void _terrainDataReceived(bool success, const TerrainPathQuery::PathHeightInfo_t& pathHeightInfo);
......@@ -288,7 +289,7 @@ public:
signals:
/// Signalled when terrain data comes back from server
void terrainData(bool success, double minHeight, double maxHeight, const QList<QList<double>>& carpet);
void terrainDataReceived(bool success, double minHeight, double maxHeight, const QList<QList<double>>& carpet);
private:
TerrainAirMapQuery _terrainQuery;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment