summaryrefslogtreecommitdiff
path: root/cpputools/source
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 /cpputools/source
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 'cpputools/source')
-rw-r--r--cpputools/source/unoexe/unoexe.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/cpputools/source/unoexe/unoexe.cxx b/cpputools/source/unoexe/unoexe.cxx
index 971ce344b08a..e02003a995e9 100644
--- a/cpputools/source/unoexe/unoexe.cxx
+++ b/cpputools/source/unoexe/unoexe.cxx
@@ -200,16 +200,16 @@ static Reference< XInterface > loadComponent(
OUString aExt( rLocation.copy( nDot +1 ) );
- if (aExt.compareToAscii( "dll" ) == 0 ||
- aExt.compareToAscii( "exe" ) == 0 ||
- aExt.compareToAscii( "dylib" ) == 0 ||
- aExt.compareToAscii( "so" ) == 0)
+ if (aExt.equalsAscii( "dll" ) ||
+ aExt.equalsAscii( "exe" ) ||
+ aExt.equalsAscii( "dylib" ) ||
+ aExt.equalsAscii( "so" ) )
{
createInstance(
xLoader, xContext, OUString("com.sun.star.loader.SharedLibrary") );
}
- else if (aExt.compareToAscii( "jar" ) == 0 ||
- aExt.compareToAscii( "class" ) == 0)
+ else if (aExt.equalsAscii( "jar" ) ||
+ aExt.equalsAscii( "class" ) )
{
createInstance(
xLoader, xContext, OUString("com.sun.star.loader.Java") );