X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FMain%2Ffg_commands.cxx;h=9303b17727f14e55cdef5540dd2a5334cbffd0f3;hb=6a9051883c1e5c1b7534ba0c833ebe86c85425a9;hp=3d965546f6be7751b1260f77c38da7cfc1c46d43;hpb=286817978d0b6233a43bc60417dcba071e3c9fd9;p=flightgear.git diff --git a/src/Main/fg_commands.cxx b/src/Main/fg_commands.cxx index 3d965546f..9303b1772 100644 --- a/src/Main/fg_commands.cxx +++ b/src/Main/fg_commands.cxx @@ -16,8 +16,10 @@ #include "fg_commands.hxx" SG_USING_STD(string); +#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS) SG_USING_STD(ifstream); SG_USING_STD(ofstream); +#endif #include "fg_props.hxx" #include "fg_io.hxx" @@ -203,17 +205,17 @@ do_property_assign (const SGPropertyNode * arg) SGPropertyNode * node = fgGetNode(propname, true); switch (node->getType()) { - case SGValue::BOOL: + case SGPropertyNode::BOOL: return node->setBoolValue(arg->getBoolValue("value")); - case SGValue::INT: + case SGPropertyNode::INT: return node->setIntValue(arg->getIntValue("value")); - case SGValue::LONG: + case SGPropertyNode::LONG: return node->setLongValue(arg->getLongValue("value")); - case SGValue::FLOAT: + case SGPropertyNode::FLOAT: return node->setFloatValue(arg->getFloatValue("value")); - case SGValue::DOUBLE: + case SGPropertyNode::DOUBLE: return node->setDoubleValue(arg->getDoubleValue("value")); - case SGValue::STRING: + case SGPropertyNode::STRING: return node->setStringValue(arg->getStringValue("value")); default: return node->setUnknownValue(arg->getStringValue("value")); @@ -237,21 +239,21 @@ do_property_adjust (const SGPropertyNode * arg) SGPropertyNode * node = fgGetNode(propname, true); switch (node->getType()) { - case SGValue::BOOL: + case SGPropertyNode::BOOL: if (arg->getBoolValue("step")) return node->setBoolValue(!node->getBoolValue()); else return true; - case SGValue::INT: + case SGPropertyNode::INT: return node->setIntValue(node->getIntValue() + arg->getIntValue("step")); - case SGValue::LONG: + case SGPropertyNode::LONG: return node->setLongValue(node->getLongValue() + arg->getLongValue("step")); - case SGValue::FLOAT: + case SGPropertyNode::FLOAT: return node->setFloatValue(node->getFloatValue() + arg->getFloatValue("step")); - case SGValue::DOUBLE: + case SGPropertyNode::DOUBLE: return node->setDoubleValue(node->getDoubleValue() + arg->getDoubleValue("step")); default: // doesn't make sense with strings