]> git.mxchange.org Git - flightgear.git/blobdiff - src/Cockpit/hud.cxx
Commented out a cout statement.
[flightgear.git] / src / Cockpit / hud.cxx
index fb7c29d1c0883dac6ef3a0aac7487488af21c2e8..9d5f5272b64a44ba18be81017bf4208771119248 100644 (file)
 
 #include <GL/glut.h>
 #include <stdlib.h>
-#include <stdio.h>     //char related functions
+#include <stdio.h>             // char related functions
+#include <string.h>            // strcmp()
 #include STL_STRING
 #include STL_FSTREAM
 
 #include <simgear/constants.h>
 #include <simgear/debug/logstream.hxx>
 #include <simgear/misc/props.hxx>
+#include <simgear/misc/sg_path.hxx>
 //#include <simgear/math/fg_random.h>
 //#include <simgear/math/polar3d.hxx>
 
@@ -391,6 +393,8 @@ readCard(const SGPropertyNode * node)
         load_fn = get_aileronval;
     } else if (loadfn=="elevatorval") {
         load_fn = get_elevatorval;
+    } else if (loadfn=="elevatortrimval") {
+        load_fn = get_elev_trimval;
     } else if (loadfn=="rudderval") {
         load_fn = get_rudderval;
     } else if (loadfn=="throttleval") {
@@ -644,10 +648,12 @@ readTBI(const SGPropertyNode * node)
 
 int readInstrument(const SGPropertyNode * node)
 {
+    static const SGPropertyNode *startup_units_node
+        = fgGetNode("/sim/startup/units");
 
     instr_item *HIptr;
     
-    if ( fgGetString("/sim/startup/units") == "feet" ) {
+    if ( !strcmp(startup_units_node->getStringValue(), "feet") ) {
         strcpy(units, " ft");
     } else {
         strcpy(units, " m");