]> git.mxchange.org Git - flightgear.git/blobdiff - src/Autopilot/route_mgr.hxx
Tie samplegroup 'avionics' to the listener, just in case no other device is created...
[flightgear.git] / src / Autopilot / route_mgr.hxx
index f409a8c4e3ab5a0186fab5a4a14bea9c03ce6009..8806cae2746a918d18d53bfacf3c95a2479c7e4e 100644 (file)
 #ifndef _ROUTE_MGR_HXX
 #define _ROUTE_MGR_HXX 1
 
-#ifndef __cplusplus
-# error This library requires C++
-#endif
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#include <simgear/compiler.h>
-
-#include <string>
-#include <vector>
-
-using std::string;
-using std::vector;
-
 #include <simgear/props/props.hxx>
 #include <simgear/route/route.hxx>
 #include <simgear/structure/subsystem_mgr.hxx>
@@ -97,6 +81,18 @@ private:
     void update_mirror();
     bool near_ground();
 
+    /**
+     * Helper to set a string property to the estimated arrival time (ETA),
+     * formatted as either hours:minutes or minutes:seconds, based on a distance
+     * and the current groundspeed.
+     */
+    void setETAPropertyFromDistance(SGPropertyNode_ptr aProp, double aDistance);
+    
+    /**
+     * Helper to update the target_altitude_ft and altitude_set flag when wp0
+     * changes
+     */
+    void updateTargetAltitude();
 public:
 
     FGRouteMgr();