From 4ccd802d9a0530ec74b52d2ad7fbaa2d085223cb Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 14 Jul 2017 10:34:38 +0200 Subject: use more OUString::operator== in svx Change-Id: Ice996c741e239767a7a15fe9b11147f5384150ba Reviewed-on: https://gerrit.libreoffice.org/39940 Tested-by: Jenkins Reviewed-by: Noel Grandin --- svx/source/unodraw/UnoNameItemTable.cxx | 10 +++++----- svx/source/unodraw/XPropertyTable.cxx | 8 ++++---- 2 files changed, 9 insertions(+), 9 deletions(-) (limited to 'svx/source/unodraw') diff --git a/svx/source/unodraw/UnoNameItemTable.cxx b/svx/source/unodraw/UnoNameItemTable.cxx index 93b1a51988c5..64c2947d5df7 100644 --- a/svx/source/unodraw/UnoNameItemTable.cxx +++ b/svx/source/unodraw/UnoNameItemTable.cxx @@ -126,7 +126,7 @@ void SAL_CALL SvxUnoNameItemTable::removeByName( const OUString& aApiName ) while( aIter != aEnd ) { const NameOrIndex *pItem = static_cast(&((*aIter)->Get( mnWhich ) )); - if (sName.equals(pItem->GetName())) + if (sName == pItem->GetName()) { maItemSetVector.erase( aIter ); return; @@ -151,7 +151,7 @@ void SAL_CALL SvxUnoNameItemTable::replaceByName( const OUString& aApiName, cons while( aIter != aEnd ) { const NameOrIndex *pItem = static_cast(&((*aIter)->Get( mnWhich ) )); - if (aName.equals(pItem->GetName())) + if (aName == pItem->GetName()) { NameOrIndex* pNewItem = createItem(); pNewItem->SetName(aName); @@ -172,7 +172,7 @@ void SAL_CALL SvxUnoNameItemTable::replaceByName( const OUString& aApiName, cons for( nSurrogate = 0; nSurrogate < nCount; nSurrogate++ ) { NameOrIndex *pItem = const_cast(static_cast(mpModelPool->GetItem2( mnWhich, nSurrogate))); - if (pItem && aName.equals(pItem->GetName())) + if (pItem && aName == pItem->GetName()) { pItem->PutValue( aElement, mnMemberId ); bFound = true; @@ -208,7 +208,7 @@ uno::Any SAL_CALL SvxUnoNameItemTable::getByName( const OUString& aApiName ) { const NameOrIndex *pItem = static_cast(mpModelPool->GetItem2( mnWhich, nSurrogate )); - if (isValid(pItem) && aName.equals(pItem->GetName())) + if (isValid(pItem) && aName == pItem->GetName()) { pItem->QueryValue( aAny, mnMemberId ); return aAny; @@ -258,7 +258,7 @@ sal_Bool SAL_CALL SvxUnoNameItemTable::hasByName( const OUString& aApiName ) for( nSurrogate = 0; nSurrogate < nCount; nSurrogate++ ) { const NameOrIndex *pItem = static_cast(mpModelPool->GetItem2( mnWhich, nSurrogate )); - if (isValid(pItem) && aName.equals(pItem->GetName())) + if (isValid(pItem) && aName == pItem->GetName()) return true; } diff --git a/svx/source/unodraw/XPropertyTable.cxx b/svx/source/unodraw/XPropertyTable.cxx index 8a21c0c6e06b..92bf5d6e396b 100644 --- a/svx/source/unodraw/XPropertyTable.cxx +++ b/svx/source/unodraw/XPropertyTable.cxx @@ -128,7 +128,7 @@ void SAL_CALL SvxUnoXPropertyTable::removeByName( const OUString& Name ) for( i = 0; i < nCount; i++ ) { const XPropertyEntry* pEntry = get(i); - if (pEntry && aInternalName.equals(pEntry->GetName())) + if (pEntry && aInternalName == pEntry->GetName()) { mpList->Remove(i); return; @@ -150,7 +150,7 @@ void SAL_CALL SvxUnoXPropertyTable::replaceByName( const OUString& aName, const for( i = 0; i < nCount; i++ ) { const XPropertyEntry* pEntry = get(i); - if (pEntry && aInternalName.equals(pEntry->GetName())) + if (pEntry && aInternalName == pEntry->GetName()) { std::unique_ptr pNewEntry(createEntry(aInternalName, aElement)); if (!pNewEntry) @@ -177,7 +177,7 @@ uno::Any SAL_CALL SvxUnoXPropertyTable::getByName( const OUString& aName ) { const XPropertyEntry* pEntry = get(i); - if (pEntry && aInternalName.equals(pEntry->GetName())) + if (pEntry && aInternalName == pEntry->GetName()) return getAny( pEntry ); } @@ -214,7 +214,7 @@ sal_Bool SAL_CALL SvxUnoXPropertyTable::hasByName( const OUString& aName ) for( i = 0; i < nCount; i++ ) { const XPropertyEntry* pEntry = get(i); - if (pEntry && aInternalName.equals(pEntry->GetName())) + if (pEntry && aInternalName == pEntry->GetName()) return true; } -- cgit