diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-03-26 10:18:32 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-03-26 12:18:09 +0100 |
commit | e443216ce2eeb2d4c7463bb019eed32f5ca4ad1c (patch) | |
tree | bbfff4052bc3ff4d2b3f9810d34774224ed1e7e1 /editeng | |
parent | 723613ab5ca5e59387dcba63d31bdb66b88035c2 (diff) |
readUnicodeString can just return the string
seeing as no-one checks the return value, we don't need
the intermediate temporary string
Diffstat (limited to 'editeng')
-rw-r--r-- | editeng/source/editeng/edtspell.cxx | 2 | ||||
-rw-r--r-- | editeng/source/editeng/impedit4.cxx | 6 | ||||
-rw-r--r-- | editeng/source/items/frmitems.cxx | 2 | ||||
-rw-r--r-- | editeng/source/items/paraitem.cxx | 2 |
4 files changed, 7 insertions, 5 deletions
diff --git a/editeng/source/editeng/edtspell.cxx b/editeng/source/editeng/edtspell.cxx index a2340aa5499b..2963f1209744 100644 --- a/editeng/source/editeng/edtspell.cxx +++ b/editeng/source/editeng/edtspell.cxx @@ -601,7 +601,7 @@ sal_Bool EdtAutoCorrDoc::SetAttr( sal_uInt16 nStt, sal_uInt16 nEnd, { SfxItemPool* pPool = &pImpEE->GetEditDoc().GetItemPool(); while ( pPool->GetSecondaryPool() && - !pPool->GetName().EqualsAscii( "EditEngineItemPool" ) ) + !pPool->GetName().equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("EditEngineItemPool")) ) { pPool = pPool->GetSecondaryPool(); diff --git a/editeng/source/editeng/impedit4.cxx b/editeng/source/editeng/impedit4.cxx index e8c2c1b2f0f5..5a23d6236fc3 100644 --- a/editeng/source/editeng/impedit4.cxx +++ b/editeng/source/editeng/impedit4.cxx @@ -169,12 +169,14 @@ EditPaM ImpEditEngine::ReadRTF( SvStream& rInput, EditSelection aSel ) // The SvRTF parser expects the Which-mapping passed on in the pool, not // dependant on a secondary. SfxItemPool* pPool = &aEditDoc.GetItemPool(); - while ( pPool->GetSecondaryPool() && !pPool->GetName().EqualsAscii( "EditEngineItemPool" ) ) + while (pPool->GetSecondaryPool() && !pPool->GetName().equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("EditEngineItemPool"))) { pPool = pPool->GetSecondaryPool(); } - DBG_ASSERT( pPool && pPool->GetName().EqualsAscii( "EditEngineItemPool" ), "ReadRTF: no EditEnginePool!" ); + + DBG_ASSERT(pPool && pPool->GetName().equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("EditEngineItemPool")), + "ReadRTF: no EditEnginePool!"); EditRTFParserRef xPrsr = new EditRTFParser( rInput, aSel, *pPool, this ); SvParserState eState = xPrsr->CallParser(); diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx index c2dbce821897..3cca643ea635 100644 --- a/editeng/source/items/frmitems.cxx +++ b/editeng/source/items/frmitems.cxx @@ -4108,7 +4108,7 @@ SvxBrushItem::SvxBrushItem( const CntWallpaperItem& rItem, sal_uInt16 _nWhich ) { aColor = rItem.GetColor(); - if( rItem.GetBitmapURL().Len() ) + if (!rItem.GetBitmapURL().isEmpty()) { pStrLink = new String( rItem.GetBitmapURL() ); SetGraphicPos( WallpaperStyle2GraphicPos((WallpaperStyle)rItem.GetStyle() ) ); diff --git a/editeng/source/items/paraitem.cxx b/editeng/source/items/paraitem.cxx index 36986d1c2efb..d7736d1c7878 100644 --- a/editeng/source/items/paraitem.cxx +++ b/editeng/source/items/paraitem.cxx @@ -1197,7 +1197,7 @@ SvStream& SvxTabStopItem::Store( SvStream& rStrm, sal_uInt16 /*nItemVersion*/ ) const SfxItemPool *pPool = SfxItemPool::GetStoringPool(); const bool bStoreDefTabs = pPool - && pPool->GetName().EqualsAscii("SWG") + && pPool->GetName().equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SWG")) && ::IsDefaultItem( this ); const short nTabs = Count(); |