diff options
author | Max Horn | 2010-10-15 12:19:13 +0000 |
---|---|---|
committer | Max Horn | 2010-10-15 12:19:13 +0000 |
commit | 36cd5caf956c087995a62983ad09c15250f29475 (patch) | |
tree | 39dc6b202fb711fef28bc7f7c49bb7611232af83 /engines/sword25/gfx/animationresource.cpp | |
parent | f52b31a05f9b234a367dd83b89cceaa3d9848204 (diff) | |
download | scummvm-rg350-36cd5caf956c087995a62983ad09c15250f29475.tar.gz scummvm-rg350-36cd5caf956c087995a62983ad09c15250f29475.tar.bz2 scummvm-rg350-36cd5caf956c087995a62983ad09c15250f29475.zip |
COMMON: Add XMLParser::parseIntegerKey variant accepting a Common::String
Almost all places where we used XMLParser::parseIntegerKey were using
it like this:
XMLParser::parseIntegerKey(str.c_str(), ...)
Since this makes the code harder to read, I overloaded the method to
also accept Commmon::String directly.
Also removed all .c_str() invocations where necessary.
svn-id: r53479
Diffstat (limited to 'engines/sword25/gfx/animationresource.cpp')
-rw-r--r-- | engines/sword25/gfx/animationresource.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/sword25/gfx/animationresource.cpp b/engines/sword25/gfx/animationresource.cpp index 96a93f1890..6609725c1b 100644 --- a/engines/sword25/gfx/animationresource.cpp +++ b/engines/sword25/gfx/animationresource.cpp @@ -116,7 +116,7 @@ bool AnimationResource::parseBooleanKey(Common::String s, bool &result) { } bool AnimationResource::parserCallback_animation(ParserNode *node) { - if (!parseIntegerKey(node->values["fps"].c_str(), 1, &_FPS) || (_FPS < MIN_FPS) || (_FPS > MAX_FPS)) { + if (!parseIntegerKey(node->values["fps"], 1, &_FPS) || (_FPS < MIN_FPS) || (_FPS > MAX_FPS)) { return parserError("Illegal or missing fps attribute in <animation> tag in \"%s\". Assuming default (\"%d\").", getFileName().c_str(), DEFAULT_FPS); } |