std::string namespace fixes.
This commit is contained in:
parent
82dd1e4be9
commit
e5bca74b9d
@ -40,15 +40,13 @@
|
||||
|
||||
#include "iochannel.hxx"
|
||||
|
||||
using std::string;
|
||||
|
||||
/**
|
||||
* A serial I/O class based on SGIOChannel.
|
||||
*/
|
||||
class SGSerial : public SGIOChannel {
|
||||
|
||||
string device;
|
||||
string baud;
|
||||
std::string device;
|
||||
std::string baud;
|
||||
SGSerialPort port;
|
||||
|
||||
char save_buf[ 2 * SG_IO_MAX_MSG_SIZE ];
|
||||
@ -68,7 +66,7 @@ public:
|
||||
* @param device_name name of serial device
|
||||
* @param baud_rate speed of communication
|
||||
*/
|
||||
SGSerial( const string& device_name, const string& baud_rate );
|
||||
SGSerial( const std::string& device_name, const std::string& baud_rate );
|
||||
|
||||
/** Destructor */
|
||||
~SGSerial();
|
||||
|
@ -38,9 +38,7 @@
|
||||
#include <simgear/structure/SGReferenced.hxx>
|
||||
|
||||
#include <map>
|
||||
|
||||
#include <string>
|
||||
using std::string;
|
||||
|
||||
class SGPropertyNode;
|
||||
|
||||
@ -69,7 +67,7 @@ public:
|
||||
* Constructor. Loads the interpolation table from the specified file.
|
||||
* @param file name of interpolation file
|
||||
*/
|
||||
SGInterpTable( const string& file );
|
||||
SGInterpTable( const std::string& file );
|
||||
|
||||
|
||||
/**
|
||||
|
@ -22,6 +22,8 @@
|
||||
|
||||
using std::istream;
|
||||
using std::ostream;
|
||||
using std::string;
|
||||
|
||||
/**
|
||||
* Condition for a single property.
|
||||
*
|
||||
|
@ -271,19 +271,19 @@ class ExtensionSupportedExpression
|
||||
{
|
||||
public:
|
||||
ExtensionSupportedExpression() {}
|
||||
ExtensionSupportedExpression(const string& extString)
|
||||
ExtensionSupportedExpression(const std::string& extString)
|
||||
: _extString(extString)
|
||||
{
|
||||
}
|
||||
const string& getExtensionString() { return _extString; }
|
||||
void setExtensionString(const string& extString) { _extString = extString; }
|
||||
const std::string& getExtensionString() { return _extString; }
|
||||
void setExtensionString(const std::string& extString) { _extString = extString; }
|
||||
void eval(bool&value, const expression::Binding* b) const
|
||||
{
|
||||
int contextId = getOperand(0)->getValue(b);
|
||||
value = isGLExtensionSupported((unsigned)contextId, _extString.c_str());
|
||||
}
|
||||
protected:
|
||||
string _extString;
|
||||
std::string _extString;
|
||||
};
|
||||
|
||||
Expression* extensionSupportedParser(const SGPropertyNode* exp,
|
||||
|
@ -36,7 +36,7 @@
|
||||
#include <boost/scoped_array.hpp>
|
||||
#include <boost/foreach.hpp>
|
||||
|
||||
typedef std::map<string, osg::observer_ptr<simgear::Effect> > EffectMap;
|
||||
typedef std::map<std::string, osg::observer_ptr<simgear::Effect> > EffectMap;
|
||||
static EffectMap lightEffectMap;
|
||||
|
||||
#define GET_COLOR_VALUE(n) \
|
||||
@ -96,7 +96,7 @@ public:
|
||||
SGLightAnimation::SGLightAnimation(const SGPropertyNode* configNode,
|
||||
SGPropertyNode* modelRoot,
|
||||
const osgDB::Options* options,
|
||||
const string &path, int i) :
|
||||
const std::string &path, int i) :
|
||||
SGAnimation(configNode, modelRoot),
|
||||
_options(options)
|
||||
{
|
||||
@ -113,7 +113,7 @@ SGLightAnimation::SGLightAnimation(const SGPropertyNode* configNode,
|
||||
_cutoff = getConfig()->getDoubleValue("cutoff");
|
||||
_near = getConfig()->getDoubleValue("near-m");
|
||||
_far = getConfig()->getDoubleValue("far-m");
|
||||
_key = path + ";" + boost::lexical_cast<string>( i );
|
||||
_key = path + ";" + boost::lexical_cast<std::string>( i );
|
||||
|
||||
SGConstPropertyNode_ptr dim_factor = configNode->getChild("dim-factor");
|
||||
if (dim_factor.valid()) {
|
||||
|
@ -23,7 +23,7 @@ class SGMaterialAnimation : public SGAnimation {
|
||||
public:
|
||||
SGMaterialAnimation(const SGPropertyNode* configNode,
|
||||
SGPropertyNode* modelRoot,
|
||||
const osgDB::Options* options,const string &path);
|
||||
const osgDB::Options* options,const std::string &path);
|
||||
virtual osg::Group* createAnimationGroup(osg::Group& parent);
|
||||
virtual void install(osg::Node& node);
|
||||
static SGPropertyNode_ptr makeEffectProperties(const SGPropertyNode* animProp);
|
||||
|
@ -344,7 +344,7 @@ SGAnimation::~SGAnimation()
|
||||
if (!_found)
|
||||
{
|
||||
std::list<std::string>::const_iterator i;
|
||||
string info;
|
||||
std::string info;
|
||||
for (i = _objectNames.begin(); i != _objectNames.end(); ++i)
|
||||
{
|
||||
if (!info.empty())
|
||||
@ -365,7 +365,7 @@ bool
|
||||
SGAnimation::animate(osg::Node* node, const SGPropertyNode* configNode,
|
||||
SGPropertyNode* modelRoot,
|
||||
const osgDB::Options* options,
|
||||
const string &path, int i)
|
||||
const std::string &path, int i)
|
||||
{
|
||||
std::string type = configNode->getStringValue("type", "none");
|
||||
if (type == "alpha-test") {
|
||||
|
@ -48,7 +48,7 @@ public:
|
||||
static bool animate(osg::Node* node, const SGPropertyNode* configNode,
|
||||
SGPropertyNode* modelRoot,
|
||||
const osgDB::Options* options,
|
||||
const string &path, int i);
|
||||
const std::string &path, int i);
|
||||
|
||||
protected:
|
||||
void apply(osg::Node* node);
|
||||
@ -354,11 +354,11 @@ public:
|
||||
SGLightAnimation(const SGPropertyNode* configNode,
|
||||
SGPropertyNode* modelRoot,
|
||||
const osgDB::Options* options,
|
||||
const string &path, int i);
|
||||
const std::string &path, int i);
|
||||
virtual osg::Group* createAnimationGroup(osg::Group& parent);
|
||||
virtual void install(osg::Node& node);
|
||||
private:
|
||||
string _light_type;
|
||||
std::string _light_type;
|
||||
SGVec3d _position;
|
||||
SGVec3d _direction;
|
||||
SGVec4d _ambient;
|
||||
@ -369,7 +369,7 @@ private:
|
||||
double _cutoff;
|
||||
double _near;
|
||||
double _far;
|
||||
string _key;
|
||||
std::string _key;
|
||||
class UpdateCallback;
|
||||
friend class UpdateCallback;
|
||||
SGSharedPtr<SGExpressiond> _animationValue;
|
||||
|
@ -26,7 +26,8 @@
|
||||
#include <vector>
|
||||
#include <functional>
|
||||
#include <set>
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <simgear/props/condition.hxx>
|
||||
#include <simgear/props/props.hxx>
|
||||
#include <simgear/math/interpolater.hxx>
|
||||
@ -949,7 +950,7 @@ namespace simgear
|
||||
{
|
||||
struct ParseError : public sg_exception
|
||||
{
|
||||
ParseError(const string& message = std::string())
|
||||
ParseError(const std::string& message = std::string())
|
||||
: sg_exception(message) {}
|
||||
};
|
||||
|
||||
@ -1014,7 +1015,7 @@ namespace simgear
|
||||
{
|
||||
public:
|
||||
size_t addBinding(const std::string& name, expression::Type type);
|
||||
bool findBinding(const string& name, VariableBinding& result) const;
|
||||
bool findBinding(const std::string& name, VariableBinding& result) const;
|
||||
std::vector<VariableBinding> bindings;
|
||||
};
|
||||
|
||||
@ -1031,7 +1032,7 @@ namespace simgear
|
||||
ParserMap& map = getParserMap();
|
||||
ParserMap::iterator itr = map.find(exp->getName());
|
||||
if (itr == map.end())
|
||||
throw ParseError(string("unknown expression ") + exp->getName());
|
||||
throw ParseError(std::string("unknown expression ") + exp->getName());
|
||||
exp_parser parser = itr->second;
|
||||
return (*parser)(exp, this);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user