#include <Navaids/route.hxx>
#include <Airports/airport.hxx>
-typedef SGSharedPtr<FGAirport> FGAirportRef;
-
namespace flightgear
{
class Transition;
-
+class FlightPlan;
+
+typedef SGSharedPtr<FlightPlan> FlightPlanRef;
+
class FlightPlan : public RouteBase
{
public:
virtual void waypointsChanged() { }
virtual void cleared() { }
virtual void currentWaypointChanged() { }
-
+ virtual void endOfFlightPlan() { }
protected:
Delegate();
void runWaypointsChanged();
void runCurrentWaypointChanged();
void runCleared();
+ void runFinished();
friend class FlightPlan;
void setCurrentIndex(int index);
+ void finish();
+
Leg* currentLeg() const;
Leg* nextLeg() const;
Leg* previousLeg() const;
_waypointsChanged,
_currentWaypointChanged;
- bool loadPlainTextRoute(const SGPath& path);
+ bool loadXmlFormat(const SGPath& path);
+ bool loadGpxFormat(const SGPath& path);
+ bool loadPlainTextFormat(const SGPath& path);
void loadVersion1XMLRoute(SGPropertyNode_ptr routeData);
void loadVersion2XMLRoute(SGPropertyNode_ptr routeData);