summaryrefslogtreecommitdiff
path: root/vcl/generic/print
diff options
context:
space:
mode:
authorThomas Arnhold <thomas@arnhold.org>2013-03-09 22:47:20 +0100
committerCédric Bosdonnat <cedric.bosdonnat@free.fr>2013-03-11 11:07:09 +0100
commit937b63af3322f7f8b5e869b2c7431a2deaec3113 (patch)
treea832f6672188551a5be9538a02fb80d6e3fc8497 /vcl/generic/print
parent5c32ac5104e9cade52c8a373033644282de9ceff (diff)
use startsWith() instead of compareToAscii()
brain damage... Change-Id: I4dc63c7346f724eded9ac7b82cda25c2bb60beff
Diffstat (limited to 'vcl/generic/print')
-rw-r--r--vcl/generic/print/genprnpsp.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/vcl/generic/print/genprnpsp.cxx b/vcl/generic/print/genprnpsp.cxx
index f01a7cfeb3b7..583587002361 100644
--- a/vcl/generic/print/genprnpsp.cxx
+++ b/vcl/generic/print/genprnpsp.cxx
@@ -86,7 +86,7 @@ static rtl::OUString getPdfDir( const PrinterInfo& rInfo )
while( nIndex != -1 )
{
rtl::OUString aToken( rInfo.m_aFeatures.getToken( 0, ',', nIndex ) );
- if( ! aToken.compareToAscii( "pdf=", 4 ) )
+ if( aToken.startsWith( "pdf=" ) )
{
sal_Int32 nPos = 0;
aDir = aToken.getToken( 1, '=', nPos );
@@ -924,7 +924,7 @@ sal_Bool PspSalPrinter::StartJob(
while( nIndex != -1 )
{
OUString aToken( rInfo.m_aFeatures.getToken( 0, ',', nIndex ) );
- if( ! aToken.compareToAscii( "fax", 3 ) )
+ if( aToken.startsWith( "fax" ) )
{
m_bFax = true;
m_aTmpFile = getTmpName();
@@ -936,11 +936,11 @@ sal_Bool PspSalPrinter::StartJob(
m_aFaxNr = it->second;
sal_Int32 nPos = 0;
- m_bSwallowFaxNo = ! aToken.getToken( 1, '=', nPos ).compareToAscii( "swallow", 7 ) ? true : false;
+ m_bSwallowFaxNo = aToken.getToken( 1, '=', nPos ).startsWith( "swallow" ) ? true : false;
break;
}
- if( ! aToken.compareToAscii( "pdf=", 4 ) )
+ if( aToken.startsWith( "pdf=" ) )
{
m_bPdf = true;
m_aTmpFile = getTmpName();
@@ -1170,7 +1170,7 @@ sal_Bool PspSalPrinter::StartJob( const rtl::OUString* i_pFileName, const rtl::O
else
osl_createTempFile( NULL, NULL, &aPDFUrl.pData );
// normalize to file URL
- if( aPDFUrl.compareToAscii( "file:", 5 ) != 0 )
+ if( !aPDFUrl.startsWith( "file:" ) )
{
// this is not a file URL, but it should
// form it into a osl friendly file URL