From: curt Date: Wed, 5 Jul 2000 18:50:34 +0000 (+0000) Subject: David Megginson: Added an interface for tree-based navigation (like X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=93c6845a6d54b1939f83bfef09188ad98ca3b901;p=simgear.git David Megginson: Added an interface for tree-based navigation (like navigating a file system.) --- diff --git a/simgear/misc/props.cxx b/simgear/misc/props.cxx index d5164226..73a8b5e4 100644 --- a/simgear/misc/props.cxx +++ b/simgear/misc/props.cxx @@ -374,7 +374,7 @@ FGValue::getStringValue () const string_val = buf; return string_val; case DOUBLE: - sprintf(buf, "%lf", getRawDouble()); + sprintf(buf, "%f", getRawDouble()); string_val = buf; return string_val; case STRING: @@ -1024,7 +1024,7 @@ get_base (const string &parent, const string &child, basename = child.substr(parent.size()); - int pos = basename.find('/'); + string::size_type pos = basename.find('/'); if (pos != string::npos) { basename.resize(pos); } @@ -1079,7 +1079,7 @@ FGPropertyNode::setPath (const string &path) const string & FGPropertyNode::getName () const { - int pos = _path.rfind('/'); + string::size_type pos = _path.rfind('/'); if (pos != string::npos) { _name = _path.substr(pos+1); return _name; @@ -1146,7 +1146,7 @@ FGPropertyNode::size () const bool FGPropertyNode::getParent (FGPropertyNode &parent) const { - int pos = _path.rfind('/'); + string::size_type pos = _path.rfind('/'); if (pos != string::npos) { parent.setPath(_path.substr(0, pos-1)); parent.setPropertyList(_props);