mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-05-04 17:30:12 +08:00
Fixed setting altitude of airport
This commit is contained in:
committed by
Mathew Sutcliffe
parent
1ec3f4566d
commit
2805979577
@@ -61,8 +61,11 @@ namespace BlackMisc
|
|||||||
{
|
{
|
||||||
CAirport airport(json.value(prefix + "icao").toString());
|
CAirport airport(json.value(prefix + "icao").toString());
|
||||||
airport.setDescriptiveName(json.value(prefix + "name").toString());
|
airport.setDescriptiveName(json.value(prefix + "name").toString());
|
||||||
airport.setElevation(CAltitude(json.value(prefix + "altitude").toInt(), CLengthUnit::ft()));
|
const CCoordinateGeodetic pos(
|
||||||
const CCoordinateGeodetic pos(json.value(prefix + "latitude").toDouble(), json.value(prefix + "longitude").toDouble(), 0);
|
json.value(prefix + "latitude").toDouble(),
|
||||||
|
json.value(prefix + "longitude").toDouble(),
|
||||||
|
json.value(prefix + "altitude").toDouble()
|
||||||
|
);
|
||||||
airport.setPosition(pos);
|
airport.setPosition(pos);
|
||||||
airport.setOperating(json.value(prefix + "operating").toString() == QStringLiteral("Y"));
|
airport.setOperating(json.value(prefix + "operating").toString() == QStringLiteral("Y"));
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user