]> git.mxchange.org Git - flightgear.git/blobdiff - src/FDM/JSBSim/FGPropertyManager.cpp
Updates from JSBSim, including new turbine engine model from David Culp
[flightgear.git] / src / FDM / JSBSim / FGPropertyManager.cpp
index 2a33172ad2bf63423a85031ea5baf403031c3912..d0f810ab8ae7a4977731bd258fb35981cb751a23 100644 (file)
@@ -47,20 +47,22 @@ COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 */
 
+namespace JSBSim {
+
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 string FGPropertyManager::mkPropertyName(string name, bool lowercase) {
   
   /* do this two pass to avoid problems with characters getting skipped
      because the index changed */
-
-  for(unsigned i=0;i<name.length();i++) {
+  unsigned i;
+  for(i=0;i<name.length();i++) {
     if( lowercase && isupper(name[i]) )
       name[i]=tolower(name[i]);
     else if( isspace(name[i]) ) 
       name[i]='-';
   }
-  for(unsigned i=0;i<name.length();i++) {
+  for(i=0;i<name.length();i++) {
     if( name[i] == '/' )
       name.erase(i,1);  
   }
@@ -312,3 +314,5 @@ void FGPropertyManager::Tie (const string &name, double *pointer,
     cout <<
           "Failed to tie property " << name << " to a pointer" << endl;
 }
+
+} // namespace JSBSim