diff options
author | Jelle van der Waa <jelle@vdwaa.nl> | 2013-06-22 12:52:31 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2013-06-24 21:44:24 +0000 |
commit | 51daa4de4fbb86903aeb9cdfefbb089e8d00c001 (patch) | |
tree | 760a9c2cf7a84714e76cfc759cafa72cbdcc07d1 | |
parent | 7b692924a83937b8fab3215fcca154d1abd4a6c8 (diff) |
fdo#43460 sd,rsc,ucb,sdext: use isEmpty()
Change-Id: I7a7a77c26b74078f7fc160fbaa1c8d4e912b844e
Reviewed-on: https://gerrit.libreoffice.org/4442
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
-rw-r--r-- | rsc/source/rsc/rsc.cxx | 4 | ||||
-rw-r--r-- | sd/source/filter/ppt/pptinanimations.cxx | 2 | ||||
-rw-r--r-- | sdext/source/pdfimport/tree/drawtreevisiting.cxx | 6 | ||||
-rw-r--r-- | sdext/source/pdfimport/tree/writertreevisiting.cxx | 10 | ||||
-rw-r--r-- | sdext/source/pdfimport/wrapper/wrapper.cxx | 2 | ||||
-rw-r--r-- | ucb/source/ucp/ftp/ftpurl.cxx | 2 |
6 files changed, 13 insertions, 13 deletions
diff --git a/rsc/source/rsc/rsc.cxx b/rsc/source/rsc/rsc.cxx index 0ef48b6cd26a..aa7a54a251f0 100644 --- a/rsc/source/rsc/rsc.cxx +++ b/rsc/source/rsc/rsc.cxx @@ -155,7 +155,7 @@ RscCmdLine::RscCmdLine( int argc, char ** argv, RscError * pEH ) { // define include path nCommands |= INCLUDE_FLAG; OStringBuffer aBuffer(aPath); - if (aBuffer.getLength()) + if (!aBuffer.isEmpty()) aBuffer.append(SAL_PATHSEPARATOR); aBuffer.append((*ppStr) + 2); aPath = aBuffer.makeStringAndClear(); @@ -636,7 +636,7 @@ ERRTYPE RscCompiler::Link() do { OString aToken = aSearchPath.getToken( 0, cSearchDelim, nIndex ); - if (aSysSearchPath.getLength()) + if (!aSysSearchPath.isEmpty()) aSysSearchPath.append(cSearchDelim); aSysSearchPath.append(aToken); aSysSearchPath.append(cAccessDelim); diff --git a/sd/source/filter/ppt/pptinanimations.cxx b/sd/source/filter/ppt/pptinanimations.cxx index 75b426dc1435..a59b7cb74477 100644 --- a/sd/source/filter/ppt/pptinanimations.cxx +++ b/sd/source/filter/ppt/pptinanimations.cxx @@ -2555,7 +2555,7 @@ bool AnimationImporter::importAttributeNamesContainer( const Atom* pAtom, OUStri OUString aName; if( aAny >>= aName ) { - if( aNames.getLength() ) + if( !aNames.isEmpty() ) aNames.append( (sal_Unicode)';' ); aNames.append( aName ); diff --git a/sdext/source/pdfimport/tree/drawtreevisiting.cxx b/sdext/source/pdfimport/tree/drawtreevisiting.cxx index 514401586fb2..e4f1d6631ffe 100644 --- a/sdext/source/pdfimport/tree/drawtreevisiting.cxx +++ b/sdext/source/pdfimport/tree/drawtreevisiting.cxx @@ -91,7 +91,7 @@ void DrawXmlEmitter::visit( HyperlinkElement& elem, const std::list< Element* >: void DrawXmlEmitter::visit( TextElement& elem, const std::list< Element* >::const_iterator& ) { - if( ! elem.Text.getLength() ) + if( elem.Text.isEmpty() ) return; OUString strSpace(32); @@ -229,14 +229,14 @@ void DrawXmlEmitter::fillFrameProps( DrawElement& rElem, } if( fRotate != 0.0 ) { - if( aBuf.getLength() > 0 ) + if( !aBuf.isEmpty() ) aBuf.append( sal_Unicode(' ') ); aBuf.appendAscii( "rotate( " ); aBuf.append( -fRotate ); aBuf.appendAscii( " )" ); } - if( aBuf.getLength() > 0 ) + if( !aBuf.isEmpty() ) aBuf.append( sal_Unicode(' ') ); aBuf.appendAscii( "translate( " ); aBuf.append( convertPixelToUnitString( rel_x ) ); diff --git a/sdext/source/pdfimport/tree/writertreevisiting.cxx b/sdext/source/pdfimport/tree/writertreevisiting.cxx index dcb863e0358a..b36a39bf0242 100644 --- a/sdext/source/pdfimport/tree/writertreevisiting.cxx +++ b/sdext/source/pdfimport/tree/writertreevisiting.cxx @@ -58,7 +58,7 @@ void WriterXmlEmitter::visit( HyperlinkElement& elem, const std::list< Element* void WriterXmlEmitter::visit( TextElement& elem, const std::list< Element* >::const_iterator& ) { - if( ! elem.Text.getLength() ) + if( elem.Text.isEmpty() ) return; PropertyMap aProps; @@ -169,7 +169,7 @@ void WriterXmlEmitter::fillFrameProps( DrawElement& rElem, } if( fRotate != 0.0 ) { - if( aBuf.getLength() > 0 ) + if( !aBuf.isEmpty() ) aBuf.append( sal_Unicode(' ') ); aBuf.appendAscii( "rotate( " ); aBuf.append( -fRotate ); @@ -178,7 +178,7 @@ void WriterXmlEmitter::fillFrameProps( DrawElement& rElem, } if( ! rElem.isCharacter ) { - if( aBuf.getLength() > 0 ) + if( !aBuf.isEmpty() ) aBuf.append( sal_Unicode(' ') ); aBuf.appendAscii( "translate( " ); aBuf.append( convertPixelToUnitString( rel_x ) ); @@ -750,9 +750,9 @@ void WriterXmlOptimizer::optimizeTextElements(Element& rParent) if( !bRotatedFrame && ! rCurGC.isRotatedOrSkewed() && ! rNextGC.isRotatedOrSkewed() - && pNext->Text.getLength() > 0 + && ! pNext->Text.isEmpty() && pNext->Text[0] != sal_Unicode(' ') - && pCur->Text.getLength() > 0 + && ! pCur->Text.isEmpty() && pCur->Text[pCur->Text.getLength() - 1] != sal_Unicode(' ') ) { diff --git a/sdext/source/pdfimport/wrapper/wrapper.cxx b/sdext/source/pdfimport/wrapper/wrapper.cxx index d091d6b58f31..2adae2043bad 100644 --- a/sdext/source/pdfimport/wrapper/wrapper.cxx +++ b/sdext/source/pdfimport/wrapper/wrapper.cxx @@ -1122,7 +1122,7 @@ bool xpdf_ImportFromFile( const OUString& rURL, // embedded fonts and bitmaps Parser aParser(rSink,pErr,xContext); OStringBuffer line; - while( osl_File_E_None == readLine(pOut, line) && line.getLength() ) + while( osl_File_E_None == readLine(pOut, line) && !line.isEmpty() ) aParser.parseLine(line.makeStringAndClear()); } } diff --git a/ucb/source/ucp/ftp/ftpurl.cxx b/ucb/source/ucp/ftp/ftpurl.cxx index 6da2bf455067..bf2c5231dba5 100644 --- a/ucb/source/ucp/ftp/ftpurl.cxx +++ b/ucb/source/ucp/ftp/ftpurl.cxx @@ -278,7 +278,7 @@ OUString FTPURL::ident(bool withslash,bool internal) const else bff.append(sal_Unicode('/')).append(m_aPathSegmentVec[i]); if(withslash) - if(bff.getLength() && bff[bff.getLength()-1] != sal_Unicode('/')) + if(!bff.isEmpty() && bff[bff.getLength()-1] != sal_Unicode('/')) bff.append(sal_Unicode('/')); bff.append(m_aType); |