cleanup
This commit is contained in:
parent
470dc1b363
commit
ff9b7ebd64
1 changed files with 5 additions and 13 deletions
|
@ -324,19 +324,11 @@ FGInput::doMouseClick (int b, int updown, int x, int y)
|
||||||
|
|
||||||
Point3D geod = sgCartToGeod(Point3D(hit[0], hit[1], hit[2]));
|
Point3D geod = sgCartToGeod(Point3D(hit[0], hit[1], hit[2]));
|
||||||
|
|
||||||
static SGPropertyNode_ptr lon
|
SGPropertyNode *c = fgGetNode("/sim/input/click", true);
|
||||||
= fgGetNode("/sim/input/click/longitude-deg", true);
|
c->setDoubleValue("longitude-deg", geod.lon() * SGD_RADIANS_TO_DEGREES);
|
||||||
static SGPropertyNode_ptr lat
|
c->setDoubleValue("latitude-deg", geod.lat() * SGD_RADIANS_TO_DEGREES);
|
||||||
= fgGetNode("/sim/input/click/latitude-deg", true);
|
c->setDoubleValue("elevation-m", geod.elev());
|
||||||
static SGPropertyNode_ptr elev_m
|
c->setDoubleValue("elevation-ft", geod.elev() * SG_METER_TO_FEET);
|
||||||
= fgGetNode("/sim/input/click/elevation-m", true);
|
|
||||||
static SGPropertyNode_ptr elev_ft
|
|
||||||
= fgGetNode("/sim/input/click/elevation-ft", true);
|
|
||||||
|
|
||||||
lon->setDoubleValue(geod.lon() * SGD_RADIANS_TO_DEGREES);
|
|
||||||
lat->setDoubleValue(geod.lat() * SGD_RADIANS_TO_DEGREES);
|
|
||||||
elev_m->setDoubleValue(geod.elev());
|
|
||||||
elev_ft->setDoubleValue(geod.elev() * SG_METER_TO_FEET);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue