]> git.mxchange.org Git - flightgear.git/commitdiff
Fix unused private vars.
authorJames Turner <zakalawe@mac.com>
Thu, 4 Jul 2013 19:24:56 +0000 (20:24 +0100)
committerJames Turner <zakalawe@mac.com>
Thu, 4 Jul 2013 19:24:56 +0000 (20:24 +0100)
Xcode is warning about these, they're a mixture of
copy-pasted code, evolved use (e.g. using a property
node to store state), and so on.

src/AIModel/AIEscort.hxx
src/AIModel/AIManager.hxx
src/Environment/atmosphere.cxx
src/Environment/atmosphere.hxx
src/Input/FGMacOSXEventInput.cxx
src/Input/FGMacOSXEventInput.hxx
src/Instrumentation/HUD/HUD_private.hxx
src/Instrumentation/slip_skid_ball.hxx
src/Instrumentation/tacan.hxx
src/Instrumentation/tcas.cxx
src/Instrumentation/tcas.hxx

index 38531eb55a4cc0b2583022a853e8ab19840b7ce9..4f0522622e2d040a2a67464f120bb7bdf84158fa 100644 (file)
@@ -76,11 +76,9 @@ private:
     SGGeod _tgtpos;
 
     bool   _solid;           // if true ground is solid for FDMs
-    double _load_resistance; // ground load resistanc N/m^2
-    double _frictionFactor;  // dimensionless modifier for Coefficient of Friction
     double _tgtrange, _tgtbrg;
     double _ht_agl_ft;
-    double _relbrg, _truebrg;
+    double _relbrg;
     double _parent_speed, _parent_hdg;
     double _interval;
 
index 605577d19efdad43fb8b67b081617b9b9fec7875..a7d2dcb8b71e812bad6fc62cdb155a9647f33e61 100644 (file)
@@ -122,7 +122,6 @@ private:
     double user_yaw;
     double user_roll;
     double user_speed;
-    double user_agl;
     double wind_from_east;
     double wind_from_north;
 
index d3f8f59e77eaca4dcabd482bf20e9e8c4e7282f6..b7130aea3e9a4a65cce7c4831cfaa49df985972c 100644 (file)
@@ -223,7 +223,7 @@ void FGAtmoCache::check_model() {
 
 //////////////////////////////////////////////////////////////////////
 
-FGAltimeter::FGAltimeter() : kset(atmodel::ISA::P0), kft(0)
+FGAltimeter::FGAltimeter()
 {
     cache();
 }
index 466cba270e60eefe4bb71f47b42576e3c935d32c..8c21186bb73979d271cfa982d24120d41e80323c 100644 (file)
@@ -136,9 +136,6 @@ public:
 
 
 class FGAltimeter : public FGAtmoCache {
-    double kset;
-    double kft;
-
 public:
     FGAltimeter();
     double reading_ft(const double p_inHg,
index 5c0fe4505d9facfd795b2d1e8a10db6bb08167f4..a969fd6e22233f135ab2843a973e285fefe2f0b7 100644 (file)
@@ -343,7 +343,7 @@ void HIDElement::generateEvent(FGMacOSXInputDevice *device, double dt, int modif
 }
 
 AxisElement::AxisElement(CFDictionaryRef element, long page, long usage) : 
-  HIDElement(element, page, usage), dead_band(0.00), saturate(1.0)
+  HIDElement(element, page, usage), dead_band(0.00)
 {
   min = GetHIDElementLongValue(element, kIOHIDElementMinKey); 
   max = GetHIDElementLongValue(element, kIOHIDElementMaxKey);
index 07e16ae135f294f7fe2745772ebb26b4a10a349a..49f059d56f9635605a49869e404ca94921764a9e 100644 (file)
@@ -119,7 +119,6 @@ private:
   long min;
   long max;
   float dead_band;
-  float saturate;
   long center;
   bool isRelative;
   bool isWrapping;
index ee787b6a7fd31b951a3ac1956b3abac7477b0a1d..9f42dcd458f0248b36b53a1884db9c86c7813de9 100644 (file)
@@ -181,9 +181,7 @@ private:
     Format  _mode;
     std::string  _format;
     int     _halign;    // HUDText alignment
-    int     _blink;
     bool    _box;
-    float   _text_y;
     float   _pointer_width;
     float   _pointer_length;
 
index 728717b22fbd74b91b5c055848c1b0dcac8ddcf7..87b691e3f0b10e07ef6c93de405f8b011004012e 100644 (file)
@@ -41,9 +41,6 @@ public:
     virtual void update (double dt);
 
 private:
-
-    double _last_pos;
-
     std::string _name;
     int _num;
 
index 48ca925f251d48f791dd7a8d31e383021e183fb4..5a38376a861313ae0ae26d8e302bd425865ca3d9 100644 (file)
@@ -93,14 +93,12 @@ private:
     SGVec3d _transmitter;
     SGGeod _transmitter_pos;
     double _transmitter_range_nm;
-    double _transmitter_bearing_deg;
     double _transmitter_bias;
     std::string _transmitter_name;
     std::string _transmitter_ident;
 
     SGGeod _mobilePos;
     double _mobile_range_nm;
-    double _mobile_bearing_deg;
     double _mobile_bias;
     std::string _mobile_name;
     std::string _mobile_ident;
index 12047c65efbc4ffc8a15cb860626de49d9260f66..519880efea679451f45c6941d6beeefcef433fdd 100644 (file)
@@ -112,11 +112,6 @@ using std::string;
 #  include <Include/no_version.h>
 #endif
 
-#include <Main/fg_props.hxx>
-#include <Main/globals.hxx>
-#include "instrument_mgr.hxx"
-#include "tcas.hxx"
-
 ///////////////////////////////////////////////////////////////////////////////
 // debug switches /////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////////////////
@@ -127,6 +122,11 @@ using std::string;
 //#define FEATURE_TCAS_DEBUG_ADV_GENERATOR
 //#define FEATURE_TCAS_DEBUG_PROPERTIES
 
+#include <Main/fg_props.hxx>
+#include <Main/globals.hxx>
+#include "instrument_mgr.hxx"
+#include "tcas.hxx"
+
 ///////////////////////////////////////////////////////////////////////////////
 // constants //////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////////////////
@@ -532,9 +532,11 @@ TCAS::AdvisoryCoordinator::update(int mode)
 
 TCAS::ThreatDetector::ThreatDetector(TCAS* _tcas) :
     tcas(_tcas),
-    checkCount(0),
     pAlarmThresholds(&sensitivityLevels[0])
 {
+#ifdef FEATURE_TCAS_DEBUG_THREAT_DETECTOR
+    checkCount = 0;
+#endif
     self.radarAltFt = 0.0;
     unitTest();
 }
index 89d929114257bd42b5ffa32bc659370814499b34..849a58f5d0d7da12e72212d5172bf9ca847c0740 100644 (file)
@@ -342,8 +342,10 @@ class TCAS : public SGSubsystem
         static const SensitivityLevel sensitivityLevels[];
 
         TCAS*              tcas;
+#ifdef FEATURE_TCAS_DEBUG_THREAT_DETECTOR
         int                checkCount;
-
+#endif // of FEATURE_TCAS_DEBUG_THREAT_DETECTOR
+        
         SGPropertyNode_ptr nodeLat;
         SGPropertyNode_ptr nodeLon;
         SGPropertyNode_ptr nodePressureAlt;