diff options
author | Szabolcs Dezsi <dezsiszabi@hotmail.com> | 2012-04-06 19:49:53 +0200 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2012-04-06 20:03:42 +0200 |
commit | d6bc02f8c4cd0f50f0a2631ac7634dab408efc1f (patch) | |
tree | b5a12df1fcae025715633469b75ab4c9b6f6d279 /xmlscript | |
parent | 0e1c0587617e0a6e4295a13599e97cdf6d1d2ea9 (diff) |
Replaced equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(...)) with == operator
Diffstat (limited to 'xmlscript')
-rw-r--r-- | xmlscript/source/xmldlg_imexp/imp_share.hxx | 14 | ||||
-rw-r--r-- | xmlscript/source/xmllib_imexp/imp_share.hxx | 4 | ||||
-rw-r--r-- | xmlscript/source/xmllib_imexp/xmllib_import.cxx | 4 |
3 files changed, 8 insertions, 14 deletions
diff --git a/xmlscript/source/xmldlg_imexp/imp_share.hxx b/xmlscript/source/xmldlg_imexp/imp_share.hxx index 33556e00bb92..bb8fbad5c7e4 100644 --- a/xmlscript/source/xmldlg_imexp/imp_share.hxx +++ b/xmlscript/source/xmldlg_imexp/imp_share.hxx @@ -70,12 +70,12 @@ inline bool getBoolAttr( ::rtl::OUString aValue( xAttributes->getValueByUidName( nUid, rAttrName ) ); if (!aValue.isEmpty()) { - if (aValue.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("true") )) + if ( aValue == "true" ) { *pRet = sal_True; return true; } - else if (aValue.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("false") )) + else if ( aValue == "false" ) { *pRet = sal_False; return true; @@ -139,14 +139,8 @@ public: inline bool isEventElement( sal_Int32 nUid, ::rtl::OUString const & rLocalName ) { - return ((XMLNS_SCRIPT_UID == nUid && - (rLocalName.equalsAsciiL( - RTL_CONSTASCII_STRINGPARAM("event") ) || - rLocalName.equalsAsciiL( - RTL_CONSTASCII_STRINGPARAM("listener-event") ))) || - (XMLNS_DIALOGS_UID == nUid && - rLocalName.equalsAsciiL( - RTL_CONSTASCII_STRINGPARAM("event") ))); + return ((XMLNS_SCRIPT_UID == nUid && (rLocalName == "event" || rLocalName == "listener-event" )) || + (XMLNS_DIALOGS_UID == nUid && rLocalName == "event" )); } void addStyle( diff --git a/xmlscript/source/xmllib_imexp/imp_share.hxx b/xmlscript/source/xmllib_imexp/imp_share.hxx index 08deae929409..a9589836df51 100644 --- a/xmlscript/source/xmllib_imexp/imp_share.hxx +++ b/xmlscript/source/xmllib_imexp/imp_share.hxx @@ -72,12 +72,12 @@ inline bool getBoolAttr( xAttributes->getValueByUidName( uid, rAttrName ) ); if (!aValue.isEmpty()) { - if (aValue.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("true") )) + if ( aValue == "true" ) { *pRet = sal_True; return true; } - else if (aValue.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("false") )) + else if ( aValue == "false" ) { *pRet = sal_False; return true; diff --git a/xmlscript/source/xmllib_imexp/xmllib_import.cxx b/xmlscript/source/xmllib_imexp/xmllib_import.cxx index 8566529e5295..f04c5e3d5342 100644 --- a/xmlscript/source/xmllib_imexp/xmllib_import.cxx +++ b/xmlscript/source/xmllib_imexp/xmllib_import.cxx @@ -179,11 +179,11 @@ Reference< xml::input::XElement > LibraryImport::startRootElement( OUString( RTL_CONSTASCII_USTRINGPARAM("illegal namespace!") ), Reference< XInterface >(), Any() ); } - else if (mpLibArray && rLocalName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("libraries") )) + else if ( mpLibArray && rLocalName == "libraries" ) { return new LibrariesElement( rLocalName, xAttributes, 0, this ); } - else if (mpLibDesc && rLocalName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("library") )) + else if ( mpLibDesc && rLocalName == "library" ) { LibDescriptor& aDesc = *mpLibDesc; aDesc.bLink = aDesc.bReadOnly = aDesc.bPasswordProtected = aDesc.bPreload = sal_False; |