fdo#43460 oox: use isEmpty()
Change-Id: If291a72d87001932c605755d628cecc088d50275 Reviewed-on: https://gerrit.libreoffice.org/4324 Reviewed-by: Noel Power <noel.power@suse.com> Tested-by: Noel Power <noel.power@suse.com>
This commit is contained in:
parent
af7cfa0071
commit
50e6713e40
@ -167,7 +167,7 @@ void ContextHandler2Helper::processCollectedChars()
|
||||
{
|
||||
OSL_ENSURE( !mxContextStack->empty(), "ContextHandler2Helper::processCollectedChars - no context info" );
|
||||
ElementInfo& rInfo = mxContextStack->back();
|
||||
if( rInfo.maChars.getLength() > 0 )
|
||||
if( !rInfo.maChars.isEmpty() )
|
||||
{
|
||||
OUString aChars = rInfo.maChars.makeStringAndClear();
|
||||
if( mbEnableTrimSpace && rInfo.mbTrimSpaces )
|
||||
|
@ -203,7 +203,7 @@ void lclPushMarkerProperties( ShapePropertyMap& rPropMap,
|
||||
break;
|
||||
}
|
||||
|
||||
if( aBuffer.getLength() > 0 )
|
||||
if( !aBuffer.isEmpty() )
|
||||
{
|
||||
sal_Int32 nLength = lclGetArrowSize( rArrowProps.moArrowLength.get( XML_med ) );
|
||||
sal_Int32 nWidth = lclGetArrowSize( rArrowProps.moArrowWidth.get( XML_med ) );
|
||||
|
@ -780,7 +780,7 @@ void DrawingML::WriteRunProperties( Reference< XPropertySet > rRun, sal_Bool bIs
|
||||
usLanguageBuffer.append( eLocale.Country );
|
||||
}
|
||||
|
||||
if( usLanguageBuffer.getLength() )
|
||||
if( !usLanguageBuffer.isEmpty() )
|
||||
usLanguage = usLanguageBuffer.makeStringAndClear();
|
||||
}
|
||||
|
||||
|
@ -86,7 +86,7 @@ void VMLExport::OpenContainer( sal_uInt16 nEscherContainer, int nRecInstance )
|
||||
m_nShapeType = ESCHER_ShpInst_Nil;
|
||||
m_pShapeAttrList = m_pSerializer->createAttrList();
|
||||
|
||||
if ( m_pShapeStyle->getLength() )
|
||||
if ( !m_pShapeStyle->isEmpty() )
|
||||
m_pShapeStyle->makeStringAndClear();
|
||||
|
||||
m_pShapeStyle->ensureCapacity( 200 );
|
||||
@ -132,7 +132,7 @@ sal_uInt32 VMLExport::EnterGroup( const OUString& rShapeName, const Rectangle* p
|
||||
if ( pRect )
|
||||
AddRectangleDimensions( aStyle, *pRect );
|
||||
|
||||
if ( aStyle.getLength() )
|
||||
if ( !aStyle.isEmpty() )
|
||||
pAttrList->add( XML_style, aStyle.makeStringAndClear() );
|
||||
|
||||
// coordorigin/coordsize
|
||||
@ -499,7 +499,7 @@ void VMLExport::Commit( EscherPropertyContainer& rProps, const Rectangle& rRect
|
||||
}
|
||||
}
|
||||
|
||||
if ( aPath.getLength() )
|
||||
if ( !aPath.isEmpty() )
|
||||
m_pShapeAttrList->add( XML_path, aPath.getStr() );
|
||||
}
|
||||
#if OSL_DEBUG_LEVEL > 0
|
||||
@ -796,7 +796,7 @@ OString VMLExport::ShapeIdString( sal_uInt32 nId )
|
||||
void VMLExport::AddLineDimensions( const Rectangle& rRectangle )
|
||||
{
|
||||
// style
|
||||
if ( m_pShapeStyle->getLength() )
|
||||
if ( !m_pShapeStyle->isEmpty() )
|
||||
m_pShapeStyle->append( ";" );
|
||||
|
||||
m_pShapeStyle->append( "position:absolute" );
|
||||
@ -840,7 +840,7 @@ void VMLExport::AddLineDimensions( const Rectangle& rRectangle )
|
||||
|
||||
void VMLExport::AddRectangleDimensions( OStringBuffer& rBuffer, const Rectangle& rRectangle )
|
||||
{
|
||||
if ( rBuffer.getLength() )
|
||||
if ( !rBuffer.isEmpty() )
|
||||
rBuffer.append( ";" );
|
||||
|
||||
rBuffer.append( "position:absolute;" );
|
||||
|
@ -119,7 +119,7 @@ const OUString& StorageBase::getName() const
|
||||
OUString StorageBase::getPath() const
|
||||
{
|
||||
OUStringBuffer aBuffer( maParentPath );
|
||||
if( aBuffer.getLength() > 0 )
|
||||
if( !aBuffer.isEmpty() )
|
||||
aBuffer.append( sal_Unicode( '/' ) );
|
||||
aBuffer.append( maStorageName );
|
||||
return aBuffer.makeStringAndClear();
|
||||
|
@ -69,7 +69,7 @@ namespace oox { namespace ppt {
|
||||
std::list< Attribute >::const_iterator iter;
|
||||
for(iter = maAttributes.begin(); iter != maAttributes.end(); ++iter)
|
||||
{
|
||||
if( sAttributes.getLength() )
|
||||
if( !sAttributes.isEmpty() )
|
||||
{
|
||||
sAttributes.appendAscii( ";" );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user