diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2013-05-16 09:24:31 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2013-05-16 09:25:53 +0200 |
commit | df18d5878c71d8d38a43dd04c0e907f9385addb4 (patch) | |
tree | 72d8da1543c6835594f37b6d75cb194fc6f775b1 /configmgr/source/valueparser.cxx | |
parent | 09269acdb98854b1892aa539efec7d6a7875ad06 (diff) |
Some string literal clean up
Change-Id: I108882af13fa97fa094547ec4efb468f988f337d
Diffstat (limited to 'configmgr/source/valueparser.cxx')
-rw-r--r-- | configmgr/source/valueparser.cxx | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/configmgr/source/valueparser.cxx b/configmgr/source/valueparser.cxx index 15b756c30dca..a8dad1922df9 100644 --- a/configmgr/source/valueparser.cxx +++ b/configmgr/source/valueparser.cxx @@ -30,7 +30,6 @@ #include "comphelper/sequenceasvector.hxx" #include "rtl/string.h" #include "rtl/string.hxx" -#include "rtl/ustring.h" #include "rtl/ustring.hxx" #include "sal/types.h" #include "xmlreader/span.hxx" @@ -68,15 +67,11 @@ bool parseHexDigit(char c, int * value) { bool parseValue(xmlreader::Span const & text, sal_Bool * value) { assert(text.is() && value != 0); - if (text.equals(RTL_CONSTASCII_STRINGPARAM("true")) || - text.equals(RTL_CONSTASCII_STRINGPARAM("1"))) - { + if (text.equals("true") || text.equals("1")) { *value = true; return true; } - if (text.equals(RTL_CONSTASCII_STRINGPARAM("false")) || - text.equals(RTL_CONSTASCII_STRINGPARAM("0"))) - { + if (text.equals("false") || text.equals("0")) { *value = false; return true; } @@ -293,8 +288,7 @@ bool ValueParser::startElement( } switch (state_) { case STATE_TEXT: - if (nsId == xmlreader::XmlReader::NAMESPACE_NONE && - name.equals(RTL_CONSTASCII_STRINGPARAM("it")) && + if (nsId == xmlreader::XmlReader::NAMESPACE_NONE && name.equals("it") && isListType(type_) && separator_.isEmpty()) { pad_.clear(); @@ -306,7 +300,7 @@ bool ValueParser::startElement( // fall through case STATE_IT: if (nsId == xmlreader::XmlReader::NAMESPACE_NONE && - name.equals(RTL_CONSTASCII_STRINGPARAM("unicode")) && + name.equals("unicode") && (type_ == TYPE_STRING || type_ == TYPE_STRING_LIST)) { sal_Int32 scalar = -1; @@ -317,7 +311,7 @@ bool ValueParser::startElement( break; } if (attrNsId == ParseManager::NAMESPACE_OOR && - attrLn.equals(RTL_CONSTASCII_STRINGPARAM("scalar"))) + attrLn.equals("scalar")) { if (!parseValue(reader.getAttributeValue(true), &scalar)) { scalar = -1; |