Kaydet (Commit) 1044a379 authored tarafından Ricardo Montania's avatar Ricardo Montania Kaydeden (comit) Tor Lillqvist

String::AppendAscii cleanup

Change-Id: I33d7a6b704cbb9a5a410b99237643c05a9c1cb9c
Reviewed-on: https://gerrit.libreoffice.org/2755Reviewed-by: 's avatarTor Lillqvist <tml@iki.fi>
Tested-by: 's avatarTor Lillqvist <tml@iki.fi>
üst 7f794d5d
......@@ -191,7 +191,8 @@ void SvxBitmapTabPage::ActivatePage( const SfxItemSet& )
// determining (possibly cutting) the name and
// displaying it in the GroupBox
String aString( CUI_RES( RID_SVXSTR_TABLE ) ); aString.AppendAscii( ": " );
OUString aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString += ": ";
INetURLObject aURL( pBitmapList->GetPath() );
aURL.Append( pBitmapList->GetName() );
......@@ -199,11 +200,11 @@ void SvxBitmapTabPage::ActivatePage( const SfxItemSet& )
if( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
if( *pPageType == PT_BITMAP && *pPos != LISTBOX_ENTRY_NOTFOUND )
{
......@@ -836,16 +837,16 @@ IMPL_LINK_NOARG(SvxBitmapTabPage, ClickLoadHdl_Impl)
// determining (possibly cutting) the name
// displaying it in the GroupBox
String aString( ResId( RID_SVXSTR_TABLE, rMgr ) );
aString.AppendAscii( ": " );
OUString aString( ResId( RID_SVXSTR_TABLE, rMgr ) );
aString += ": ";
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
*pnBitmapListState |= CT_CHANGED;
*pnBitmapListState &= ~CT_MODIFIED;
......@@ -912,16 +913,16 @@ IMPL_LINK_NOARG(SvxBitmapTabPage, ClickSaveHdl_Impl)
{
// determining (possibly cutting) the name
// displaying it in the GroupBox
String aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString.AppendAscii( ": " );
OUString aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString += ": ";
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
*pnBitmapListState |= CT_SAVED;
*pnBitmapListState &= ~CT_MODIFIED;
......
......@@ -109,8 +109,8 @@ void SvxColorTabPage::HideLoadSaveEmbed()
void SvxColorTabPage::UpdateTableName()
{
// Truncate the name if necessary ...
String aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString.AppendAscii( ": " );
OUString aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString += ": ";
XPropertyListRef pList = GetList();
if( !pList.is() )
......@@ -121,11 +121,11 @@ void SvxColorTabPage::UpdateTableName()
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String (aURL.getBase());
aString += aURL.getBase();
m_pTableName->SetText( aString );
}
......
......@@ -200,7 +200,8 @@ void SvxGradientTabPage::ActivatePage( const SfxItemSet& )
// determining (and possibly cutting) the name and
// displaying it in the GroupBox
String aString( CUI_RES( RID_SVXSTR_TABLE ) ); aString.AppendAscii( ": " );
OUString aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString += ": ";
INetURLObject aURL( pGradientList->GetPath() );
aURL.Append( pGradientList->GetName() );
......@@ -208,11 +209,11 @@ void SvxGradientTabPage::ActivatePage( const SfxItemSet& )
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
if ( *pPageType == PT_GRADIENT && *pPos != LISTBOX_ENTRY_NOTFOUND )
{
......@@ -669,16 +670,16 @@ IMPL_LINK_NOARG(SvxGradientTabPage, ClickLoadHdl_Impl)
// determining (possibly cutting) the name
// and displaying it in the GroupBox
String aString( ResId( RID_SVXSTR_TABLE, rMgr ) );
aString.AppendAscii( ": " );
OUString aString( ResId( RID_SVXSTR_TABLE, rMgr ) );
aString += ": ";
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
*pnGradientListState |= CT_CHANGED;
*pnGradientListState &= ~CT_MODIFIED;
......@@ -745,16 +746,16 @@ IMPL_LINK_NOARG(SvxGradientTabPage, ClickSaveHdl_Impl)
{
// determining (possibly cutting) the name
// and displaying it in the GroupBox
String aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString.AppendAscii( ": " );
OUString aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString += ": ";
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
*pnGradientListState |= CT_SAVED;
*pnGradientListState &= ~CT_MODIFIED;
......
......@@ -189,7 +189,8 @@ void SvxHatchTabPage::ActivatePage( const SfxItemSet& rSet )
// determining (possibly cutting) the name
// and displaying it in the GroupBox
String aString( CUI_RES( RID_SVXSTR_TABLE ) ); aString.AppendAscii( ": " );
OUString aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString += ": ";
INetURLObject aURL( pHatchingList->GetPath() );
aURL.Append( pHatchingList->GetName() );
......@@ -197,11 +198,11 @@ void SvxHatchTabPage::ActivatePage( const SfxItemSet& rSet )
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
if( *pPageType == PT_HATCH && *pPos != LISTBOX_ENTRY_NOTFOUND )
{
......@@ -713,16 +714,16 @@ IMPL_LINK_NOARG(SvxHatchTabPage, ClickLoadHdl_Impl)
// determining (and possibly cutting) the name
// and displaying it in the GroupBox
String aString( ResId( RID_SVXSTR_TABLE, rMgr ) );
aString.AppendAscii( ": " );
OUString aString( ResId( RID_SVXSTR_TABLE, rMgr ) );
aString += ": ";
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
*pnHatchingListState |= CT_CHANGED;
*pnHatchingListState &= ~CT_MODIFIED;
......@@ -785,16 +786,16 @@ IMPL_LINK_NOARG(SvxHatchTabPage, ClickSaveHdl_Impl)
{
// determining (and possibly cutting) the name
// and displaying it in the GroupBox
String aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString.AppendAscii( ": " );
OUString aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString += ": ";
if ( aURL.getBase().getLength() > 18 )
{
aString += String(aURL.getBase()).Copy( 0, 15 );
aString.AppendAscii( "..." );
aString += aURL.getBase().copy( 0, 15 );
aString += "...";
}
else
aString += String(aURL.getBase());
aString += aURL.getBase();
*pnHatchingListState |= CT_SAVED;
*pnHatchingListState &= ~CT_MODIFIED;
......
......@@ -192,7 +192,8 @@ void SvxLineDefTabPage::ActivatePage( const SfxItemSet& )
// determining (and possibly cutting) the name
// and displaying it in the GroupBox
String aString( CUI_RES( RID_SVXSTR_TABLE ) ); aString.AppendAscii( ": " );
OUString aString( CUI_RES( RID_SVXSTR_TABLE ) );
aString += ": ";
INetURLObject aURL( pDashList->GetPath() );
aURL.Append( pDashList->GetName() );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment