summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2013-11-05 14:39:55 +0200
committerNoel Grandin <noel@peralex.com>2013-11-11 12:58:13 +0200
commitfcd1637d5101b9142e6808edfb77b01122857901 (patch)
tree5fd09f97de80cf2a9481bd55a798015db35f1d0c /sd
parentef90021abe3735fba57145598fd7c3d359d2718e (diff)
convert OUString compareToAscii == 0 to equalsAscii
Convert code like aStr.compareToAscii("XXX") == 0 to aStr.equalsAscii("XXX") which is both easier to read and faster. Change-Id: I448abf58f2fa0e7715dba53f8e8825ca0587c83f
Diffstat (limited to 'sd')
-rw-r--r--sd/source/filter/eppt/pptexanimations.cxx2
-rw-r--r--sd/source/filter/ppt/pptinanimations.cxx4
-rw-r--r--sd/source/ui/dlg/dlgass.cxx4
-rw-r--r--sd/source/ui/framework/factories/FullScreenPane.cxx2
-rw-r--r--sd/source/ui/remotecontrol/ImagePreparer.cxx2
5 files changed, 7 insertions, 7 deletions
diff --git a/sd/source/filter/eppt/pptexanimations.cxx b/sd/source/filter/eppt/pptexanimations.cxx
index 355877ce9e0b..6ad06d633759 100644
--- a/sd/source/filter/eppt/pptexanimations.cxx
+++ b/sd/source/filter/eppt/pptexanimations.cxx
@@ -98,7 +98,7 @@ void ImplTranslateAttribute( OUString& rString, const TranslateMode eTranslateMo
const ImplAttributeNameConversion* p = gImplConversionList;
while( p->mpAPIName )
{
- if( rString.compareToAscii( p->mpAPIName ) == 0 )
+ if( rString.equalsAscii( p->mpAPIName ) )
break;
p++;
}
diff --git a/sd/source/filter/ppt/pptinanimations.cxx b/sd/source/filter/ppt/pptinanimations.cxx
index 5bfac6ade440..3d7daa85cc7d 100644
--- a/sd/source/filter/ppt/pptinanimations.cxx
+++ b/sd/source/filter/ppt/pptinanimations.cxx
@@ -91,7 +91,7 @@ const transition* transition::find( const OUString& rName )
while( p->mpName )
{
- if( rName.compareToAscii( p->mpName ) == 0 )
+ if( rName.equalsAscii( p->mpName ) )
return p;
p++;
@@ -698,7 +698,7 @@ bool AnimationImporter::convertAnimationNode( const Reference< XAnimationNode >&
{
while( p->mpMSName )
{
- if( aAttributeName.compareToAscii( p->mpMSName ) == 0 )
+ if( aAttributeName.equalsAscii( p->mpMSName ) )
break;
p++;
diff --git a/sd/source/ui/dlg/dlgass.cxx b/sd/source/ui/dlg/dlgass.cxx
index 76179bd37cd4..58e5d25e3073 100644
--- a/sd/source/ui/dlg/dlgass.cxx
+++ b/sd/source/ui/dlg/dlgass.cxx
@@ -807,9 +807,9 @@ void AssistentDlgImpl::ScanDocmenu (void)
OUString sFactoryName;
for( sal_Int32 i=0; i<nPropCount; ++i )
{
- if( lProps[i].Name.compareToAscii( "DocumentService" ) == 0 &&
+ if( lProps[i].Name.equalsAscii( "DocumentService" ) &&
(lProps[i].Value >>= sFactoryName) &&
- sFactoryName.compareToAscii( "com.sun.star.presentation.PresentationDocument" ) == 0 )
+ sFactoryName.equalsAscii( "com.sun.star.presentation.PresentationDocument" ) )
{
// yes, it's an impress document
INetURLObject aURL;
diff --git a/sd/source/ui/framework/factories/FullScreenPane.cxx b/sd/source/ui/framework/factories/FullScreenPane.cxx
index f2804c1f20b5..281c4650b5d5 100644
--- a/sd/source/ui/framework/factories/FullScreenPane.cxx
+++ b/sd/source/ui/framework/factories/FullScreenPane.cxx
@@ -270,7 +270,7 @@ void FullScreenPane::ExtractArguments (
const OUString sKey = aToken.copy(0, nAssign);
const OUString sValue = aToken.copy(nAssign+1);
- if (sKey.compareToAscii("ScreenNumber") == 0)
+ if (sKey.equalsAscii("ScreenNumber"))
{
rnScreenNumberReturnValue = sValue.toInt32();
}
diff --git a/sd/source/ui/remotecontrol/ImagePreparer.cxx b/sd/source/ui/remotecontrol/ImagePreparer.cxx
index f9641b0b4951..7baa1aa64c3f 100644
--- a/sd/source/ui/remotecontrol/ImagePreparer.cxx
+++ b/sd/source/ui/remotecontrol/ImagePreparer.cxx
@@ -305,7 +305,7 @@ sal_Bool ExportTo( uno::Reference< drawing::XDrawPage>& aNotesPage, OUString aUr
for ( sal_Int32 nFilterProp = 0; nFilterProp<nFilterProps; nFilterProp++ )
{
const beans::PropertyValue& rFilterProp = aProps[nFilterProp];
- if ( rFilterProp.Name.compareToAscii("FilterService") == 0 )
+ if ( rFilterProp.Name.equalsAscii("FilterService") )
{
rFilterProp.Value >>= aFilterImplName;
break;