summaryrefslogtreecommitdiff
path: root/svx/source/items/pageitem.cxx
diff options
context:
space:
mode:
authorJean-Noël Rouvignac <jn.rouvignac@gmail.com>2013-01-23 12:41:52 +0100
committerMichael Stahl <mstahl@redhat.com>2013-01-28 17:36:20 +0100
commit0dc532bffcda35d15a4719c05bb258e470355b98 (patch)
treeec7adac5e52ca5aebb52d06a2498654af82e1200 /svx/source/items/pageitem.cxx
parent7e8e9031c6ef46d67d5579ca42d0c0f5975d4f98 (diff)
fdo#38838 Some removal/replacement of the String/UniString with OUString
Changed SfxItemPool::GetPresentation( SfxItemPresentation ePres, SfxMapUnit eCoreMetric, SfxMapUnit ePresMetric, String &rText ) const; to use OUString. Change-Id: I656c1d321ff96f1f2e5b77f6adc103ef0a6fdf66
Diffstat (limited to 'svx/source/items/pageitem.cxx')
-rw-r--r--svx/source/items/pageitem.cxx27
1 files changed, 11 insertions, 16 deletions
diff --git a/svx/source/items/pageitem.cxx b/svx/source/items/pageitem.cxx
index 67d491dedb58..ce4a265895fe 100644
--- a/svx/source/items/pageitem.cxx
+++ b/svx/source/items/pageitem.cxx
@@ -101,10 +101,11 @@ SfxItemPresentation SvxPageItem::GetPresentation
SfxItemPresentation ePres,
SfxMapUnit /*eCoreUnit*/,
SfxMapUnit /*ePresUnit*/,
- XubString& rText, const IntlWrapper *
+ OUString& rText, const IntlWrapper *
) const
{
- rText.Erase();
+ rText = OUString();
+ OUString cpDelimTmp = OUString(cpDelim);
switch ( ePres )
{
@@ -114,12 +115,10 @@ SfxItemPresentation SvxPageItem::GetPresentation
{
if ( aDescName.Len() )
{
- rText = aDescName;
- rText += cpDelim;
+ rText = aDescName + cpDelimTmp;
}
DBG_ASSERT( eNumType <= SVX_NUMBER_NONE, "enum overflow" );
- rText += SVX_RESSTR(RID_SVXITEMS_PAGE_NUM_BEGIN + eNumType);
- rText += cpDelim;
+ rText += SVX_RESSTR(RID_SVXITEMS_PAGE_NUM_BEGIN + eNumType) + cpDelimTmp;
if ( bLandscape )
rText += SVX_RESSTR(RID_SVXITEMS_PAGE_LAND_TRUE);
else
@@ -127,8 +126,7 @@ SfxItemPresentation SvxPageItem::GetPresentation
String aUsageText = GetUsageText( eUse );
if (aUsageText.Len())
{
- rText += cpDelim;
- rText += aUsageText;
+ rText += cpDelimTmp + aUsageText;
}
return SFX_ITEM_PRESENTATION_NAMELESS;
}
@@ -137,12 +135,10 @@ SfxItemPresentation SvxPageItem::GetPresentation
rText += SVX_RESSTR(RID_SVXITEMS_PAGE_COMPLETE);
if ( aDescName.Len() )
{
- rText += aDescName;
- rText += cpDelim;
+ rText += aDescName + cpDelimTmp;
}
DBG_ASSERT( eNumType <= SVX_NUMBER_NONE, "enum overflow" );
- rText += SVX_RESSTR(RID_SVXITEMS_PAGE_NUM_BEGIN + eNumType);
- rText += cpDelim;
+ rText += SVX_RESSTR(RID_SVXITEMS_PAGE_NUM_BEGIN + eNumType) + cpDelimTmp;
if ( bLandscape )
rText += SVX_RESSTR(RID_SVXITEMS_PAGE_LAND_TRUE);
else
@@ -150,8 +146,7 @@ SfxItemPresentation SvxPageItem::GetPresentation
String aUsageText = GetUsageText( eUse );
if (aUsageText.Len())
{
- rText += cpDelim;
- rText += aUsageText;
+ rText += cpDelimTmp + aUsageText;
}
return SFX_ITEM_PRESENTATION_COMPLETE;
}
@@ -307,10 +302,10 @@ SfxItemPresentation SvxSetItem::GetPresentation
SfxItemPresentation /*ePres*/,
SfxMapUnit /*eCoreUnit*/,
SfxMapUnit /*ePresUnit*/,
- XubString& rText, const IntlWrapper *
+ OUString& rText, const IntlWrapper *
) const
{
- rText.Erase();
+ rText = OUString();
return SFX_ITEM_PRESENTATION_NONE;
}