]> git.mxchange.org Git - flightgear.git/blobdiff - src/FDM/JSBSim/models/FGGasCell.cpp
Removed useless divisions - As a side effect, it removes the risk of divisions by...
[flightgear.git] / src / FDM / JSBSim / models / FGGasCell.cpp
index 3b1278fa4bd1b9332663f7445f854e61a9482a8d..bdab7217237b3414a49d1a259eadb7844b9d2085 100644 (file)
@@ -41,14 +41,19 @@ INCLUDES
 #include "models/FGInertial.h"
 #include "models/FGMassBalance.h"
 #include "FGGasCell.h"
+#include "input_output/FGXMLElement.h"
+#include <iostream>
+#include <cstdlib>
 
 using std::cerr;
 using std::endl;
 using std::cout;
+using std::string;
+using std::max;
 
 namespace JSBSim {
 
-static const char *IdSrc = "$Id$";
+static const char *IdSrc = "$Id: FGGasCell.cpp,v 1.13 2010/12/29 22:39:25 andgi Exp $";
 static const char *IdHdr = ID_GASCELL;
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -201,20 +206,20 @@ FGGasCell::FGGasCell(FGFDMExec* exec, Element* el, int num) : FGForce(exec)
   base_property_name = CreateIndexedPropertyName("buoyant_forces/gas-cell", CellNum);
 
   property_name = base_property_name + "/max_volume-ft3";
-  PropertyManager->Tie( property_name.c_str(), &MaxVolume );
+  PropertyManager->Tie( property_name.c_str(), &MaxVolume, false );
   PropertyManager->SetWritable( property_name, false );
   property_name = base_property_name + "/temp-R";
-  PropertyManager->Tie( property_name.c_str(), &Temperature );
+  PropertyManager->Tie( property_name.c_str(), &Temperature, false );
   property_name = base_property_name + "/pressure-psf";
-  PropertyManager->Tie( property_name.c_str(), &Pressure );
+  PropertyManager->Tie( property_name.c_str(), &Pressure, false );
   property_name = base_property_name + "/volume-ft3";
-  PropertyManager->Tie( property_name.c_str(), &Volume );
+  PropertyManager->Tie( property_name.c_str(), &Volume, false );
   property_name = base_property_name + "/buoyancy-lbs";
-  PropertyManager->Tie( property_name.c_str(), &Buoyancy );
+  PropertyManager->Tie( property_name.c_str(), &Buoyancy, false );
   property_name = base_property_name + "/contents-mol";
-  PropertyManager->Tie( property_name.c_str(), &Contents );
+  PropertyManager->Tie( property_name.c_str(), &Contents, false );
   property_name = base_property_name + "/valve_open";
-  PropertyManager->Tie( property_name.c_str(), &ValveOpen );
+  PropertyManager->Tie( property_name.c_str(), &ValveOpen, false );
 
   Debug(0);
 
@@ -641,23 +646,23 @@ FGBallonet::FGBallonet(FGFDMExec* exec, Element* el, int num, FGGasCell* parent)
   base_property_name = CreateIndexedPropertyName(base_property_name + "/ballonet", CellNum);
 
   property_name = base_property_name + "/max_volume-ft3";
-  PropertyManager->Tie( property_name, &MaxVolume );
+  PropertyManager->Tie( property_name, &MaxVolume, false );
   PropertyManager->SetWritable( property_name, false );
 
   property_name = base_property_name + "/temp-R";
-  PropertyManager->Tie( property_name, &Temperature );
+  PropertyManager->Tie( property_name, &Temperature, false );
 
   property_name = base_property_name + "/pressure-psf";
-  PropertyManager->Tie( property_name, &Pressure );
+  PropertyManager->Tie( property_name, &Pressure, false );
 
   property_name = base_property_name + "/volume-ft3";
-  PropertyManager->Tie( property_name, &Volume );
+  PropertyManager->Tie( property_name, &Volume, false );
 
   property_name = base_property_name + "/contents-mol";
-  PropertyManager->Tie( property_name, &Contents );
+  PropertyManager->Tie( property_name, &Contents, false );
 
   property_name = base_property_name + "/valve_open";
-  PropertyManager->Tie( property_name, &ValveOpen );
+  PropertyManager->Tie( property_name, &ValveOpen, false );
 
   Debug(0);