From 8da2f1a31b019201d950eaed663b40a5a0b73472 Mon Sep 17 00:00:00 2001 From: ehofman Date: Tue, 29 Dec 2009 13:56:18 +0000 Subject: [PATCH] Use SGPropertyNode_ptr wherever possible --- src/AIModel/AIEscort.cxx | 4 ++-- src/AIModel/AIEscort.hxx | 2 +- src/AIModel/AIGroundVehicle.cxx | 4 ++-- src/AIModel/AIGroundVehicle.hxx | 2 +- src/Autopilot/autobrake.hxx | 2 +- src/Instrumentation/gps.hxx | 2 +- src/Instrumentation/instrument_mgr.hxx | 2 +- src/Instrumentation/navradio.hxx | 4 ++-- src/Systems/electrical.hxx | 2 +- src/Systems/system_mgr.hxx | 2 +- 10 files changed, 13 insertions(+), 13 deletions(-) diff --git a/src/AIModel/AIEscort.cxx b/src/AIModel/AIEscort.cxx index 760378e78..c9901ca24 100644 --- a/src/AIModel/AIEscort.cxx +++ b/src/AIModel/AIEscort.cxx @@ -235,10 +235,10 @@ bool FGAIEscort::getGroundElev(SGGeod inpos) { void FGAIEscort::setParent() { - const SGPropertyNode *ai = fgGetNode("/ai/models", true); + const SGPropertyNode_ptr ai = fgGetNode("/ai/models", true); for (int i = ai->nChildren() - 1; i >= -1; i--) { - const SGPropertyNode *model; + SGPropertyNode_ptr model; if (i < 0) { // last iteration: selected model model = _selected_ac; diff --git a/src/AIModel/AIEscort.hxx b/src/AIModel/AIEscort.hxx index ebc442475..d5adff5d5 100644 --- a/src/AIModel/AIEscort.hxx +++ b/src/AIModel/AIEscort.hxx @@ -95,7 +95,7 @@ private: double _max_speed; const SGMaterial* _material; - const SGPropertyNode *_selected_ac; + SGPropertyNode_ptr _selected_ac; bool _MPControl, _patrol, _stn_deg_true; diff --git a/src/AIModel/AIGroundVehicle.cxx b/src/AIModel/AIGroundVehicle.cxx index f7a6a1d9f..bde684941 100644 --- a/src/AIModel/AIGroundVehicle.cxx +++ b/src/AIModel/AIGroundVehicle.cxx @@ -349,10 +349,10 @@ bool FGAIGroundVehicle::getPitch() { void FGAIGroundVehicle::setParent() { - const SGPropertyNode *ai = fgGetNode("/ai/models", true); + const SGPropertyNode_ptr ai = fgGetNode("/ai/models", true); for (int i = ai->nChildren() - 1; i >= -1; i--) { - const SGPropertyNode *model; + SGPropertyNode_ptr model; if (i < 0) { // last iteration: selected model model = _selected_ac; diff --git a/src/AIModel/AIGroundVehicle.hxx b/src/AIModel/AIGroundVehicle.hxx index f1f4085a9..721ebf303 100644 --- a/src/AIModel/AIGroundVehicle.hxx +++ b/src/AIModel/AIGroundVehicle.hxx @@ -96,7 +96,7 @@ private: double _dt_count, _next_run, _break_count; const SGMaterial* _material; - const SGPropertyNode *_selected_ac; + SGPropertyNode_ptr _selected_ac; string _parent; diff --git a/src/Autopilot/autobrake.hxx b/src/Autopilot/autobrake.hxx index 4dbf7555d..2a6845c66 100644 --- a/src/Autopilot/autobrake.hxx +++ b/src/Autopilot/autobrake.hxx @@ -92,7 +92,7 @@ private: double _rightBrakeOutput; SGPropertyNode_ptr _root; - SGPropertyNode* _brakeInputs[4]; + SGPropertyNode_ptr _brakeInputs[4]; SGPropertyNode_ptr _weightOnWheelsNode; SGPropertyNode_ptr _engineControlsNode; SGPropertyNode_ptr _groundspeedNode; diff --git a/src/Instrumentation/gps.hxx b/src/Instrumentation/gps.hxx index 76596773a..d20c74e48 100644 --- a/src/Instrumentation/gps.hxx +++ b/src/Instrumentation/gps.hxx @@ -419,7 +419,7 @@ private: SGPropertyNode_ptr _apTargetAltitudeFt; SGPropertyNode_ptr _apAltitudeLock; - std::vector _tiedNodes; + std::vector _tiedNodes; }; diff --git a/src/Instrumentation/instrument_mgr.hxx b/src/Instrumentation/instrument_mgr.hxx index 00b6ddfd1..8224e85f5 100644 --- a/src/Instrumentation/instrument_mgr.hxx +++ b/src/Instrumentation/instrument_mgr.hxx @@ -34,7 +34,7 @@ public: bool build (); private: - SGPropertyNode *config_props; + SGPropertyNode_ptr config_props; bool _explicitGps; }; diff --git a/src/Instrumentation/navradio.hxx b/src/Instrumentation/navradio.hxx index 0337bf219..41d662ff0 100644 --- a/src/Instrumentation/navradio.hxx +++ b/src/Instrumentation/navradio.hxx @@ -168,7 +168,7 @@ class FGNavRadio : public SGSubsystem double _gsNeedleDeflectionNorm; SGSharedPtr _sgr; - std::vector _tiedNodes; + std::vector _tiedNodes; bool updateWithPower(double aDt); @@ -208,7 +208,7 @@ class FGNavRadio : public SGSubsystem template void tie(const char* aRelPath, const SGRawValue& aRawValue) { - SGPropertyNode* nd = _radio_node->getNode(aRelPath, true); + SGPropertyNode_ptr nd = _radio_node->getNode(aRelPath, true); _tiedNodes.push_back(nd); nd->tie(aRawValue); } diff --git a/src/Systems/electrical.hxx b/src/Systems/electrical.hxx index a9e85039b..c63b8c35f 100644 --- a/src/Systems/electrical.hxx +++ b/src/Systems/electrical.hxx @@ -266,7 +266,7 @@ private: string name; int num; string path; - SGPropertyNode *config_props; + SGPropertyNode_ptr config_props; bool enabled; diff --git a/src/Systems/system_mgr.hxx b/src/Systems/system_mgr.hxx index e783532e2..a5403580f 100644 --- a/src/Systems/system_mgr.hxx +++ b/src/Systems/system_mgr.hxx @@ -34,7 +34,7 @@ public: bool build (); private: - SGPropertyNode *config_props; + SGPropertyNode_ptr config_props; bool enabled; }; -- 2.39.5