diff options
author | Kayo Hamid <kayo.hamid@gekkolinux.com.br> | 2011-04-22 23:41:55 -0400 |
---|---|---|
committer | Michael Meeks <michael.meeks@novell.com> | 2011-04-26 15:24:32 +0100 |
commit | 5dd4f9ecb2f50cf76b44472e4438297b6c65184c (patch) | |
tree | 0f36d451a7b3e586458bf200561dbbbd4745e85b /sdext | |
parent | d5d6fd656c29b81c7e7d9c3ce21573ed6681ffae (diff) |
inefficient emptiness check
Diffstat (limited to 'sdext')
-rw-r--r-- | sdext/source/minimizer/pagecollector.cxx | 2 | ||||
-rw-r--r-- | sdext/source/pdfimport/tree/pdfiprocessor.cxx | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/sdext/source/minimizer/pagecollector.cxx b/sdext/source/minimizer/pagecollector.cxx index 101582c9983a..811d63f8b96c 100644 --- a/sdext/source/minimizer/pagecollector.cxx +++ b/sdext/source/minimizer/pagecollector.cxx @@ -96,7 +96,7 @@ void PageCollector::CollectNonCustomShowPages( const com::sun::star::uno::Refere { std::vector< Reference< XDrawPage > > vUsedPageList; PageCollector::CollectCustomShowPages( rxModel, rCustomShowName, vUsedPageList ); - if ( vUsedPageList.size() ) + if ( !vUsedPageList.empty() ) { Reference< XDrawPagesSupplier > xDrawPagesSupplier( rxModel, UNO_QUERY_THROW ); Reference< XDrawPages > xDrawPages( xDrawPagesSupplier->getDrawPages(), UNO_QUERY_THROW ); diff --git a/sdext/source/pdfimport/tree/pdfiprocessor.cxx b/sdext/source/pdfimport/tree/pdfiprocessor.cxx index 238f78c8f647..ffc905df7c84 100644 --- a/sdext/source/pdfimport/tree/pdfiprocessor.cxx +++ b/sdext/source/pdfimport/tree/pdfiprocessor.cxx @@ -221,7 +221,7 @@ sal_Int32 PDFIProcessor::getFontId( const FontAttributes& rAttr ) const // line diagnose block - start void PDFIProcessor::processGlyphLine() { - if( m_GlyphsList.size()<1 ) + if( m_GlyphsList.empty() ) return; double fPreAvarageSpaceValue= 0.0; @@ -317,7 +317,7 @@ void PDFIProcessor::processGlyphLine() ParagraphElement* pPara= NULL ; FrameElement* pFrame= NULL ; - if(m_GlyphsList.size()>0) + if(!m_GlyphsList.empty()) { pFrame = m_pElFactory->createFrameElement( m_GlyphsList[0].getCurElement(), getGCId( getTransformGlyphContext( m_GlyphsList[0])) ); pFrame->ZOrder = m_nNextZOrder++; @@ -401,7 +401,7 @@ void PDFIProcessor::processGlyphLine() } - if(m_GlyphsList.size()>1) + if(!m_GlyphsList.empty()) processGlyph( 0, m_GlyphsList[m_GlyphsList.size()-1], pPara, |