]> git.mxchange.org Git - flightgear.git/commitdiff
GPS / route-manager: only drive autopilot true-heading in LEG mode, for compatibility...
authorjmt <jmt>
Tue, 22 Dec 2009 12:05:52 +0000 (12:05 +0000)
committerTim Moore <timoore@redhat.com>
Wed, 23 Dec 2009 08:40:58 +0000 (09:40 +0100)
src/Instrumentation/gps.cxx

index 1dd72d9fcb672e07f53f886578b4153ee9304d4d..3303b669c4882fe0130df2f49420bda02a87a710 100644 (file)
@@ -1003,8 +1003,12 @@ void GPS::driveAutopilot()
     return;
   }
  
-  // FIXME: we want to set desired track, not heading, here
-  _apTrueHeading->setDoubleValue(getWP1Bearing());
+  // compatability feature - allow the route-manager / GPS to drive the
+  // generic autopilot heading hold *in leg mode only* 
+  if (_mode == "leg") {
+    // FIXME: we want to set desired track, not heading, here
+    _apTrueHeading->setDoubleValue(getWP1Bearing());
+  }
 }
 
 void GPS::wp1Changed()