summaryrefslogtreecommitdiff
path: root/basctl
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2012-06-11 13:15:18 +0100
committerCaolán McNamara <caolanm@redhat.com>2012-06-11 14:46:46 +0100
commit8f5629fd5aafc85e509a4160a11a285b0a66e7c0 (patch)
tree143883c85467b5ce9f5c665338e0f8a25067a0cd /basctl
parent2106d8e648449d34b195068eef5f672a14ea64a8 (diff)
remove EraseLeadingChars and EraseTrailingChars
Change-Id: Ib9797fe97cd008cc6508ce8cec47dc5373416892
Diffstat (limited to 'basctl')
-rw-r--r--basctl/source/basicide/baside2b.cxx12
1 files changed, 4 insertions, 8 deletions
diff --git a/basctl/source/basicide/baside2b.cxx b/basctl/source/basicide/baside2b.cxx
index ebb67bfb641c..c43ea051f246 100644
--- a/basctl/source/basicide/baside2b.cxx
+++ b/basctl/source/basicide/baside2b.cxx
@@ -126,9 +126,8 @@ void lcl_SeparateNameAndIndex( const String& rVName, String& rVar, String& rInde
{
rIndex = rVar.Copy( nIndexStart+1, nIndexEnd-nIndexStart-1 );
rVar.Erase( nIndexStart );
- rVar.EraseTrailingChars();
- rIndex.EraseLeadingChars();
- rIndex.EraseTrailingChars();
+ rVar = comphelper::string::stripEnd(rVar, ' ');
+ rIndex = comphelper::string::strip(rIndex, ' ');
}
}
@@ -1948,8 +1947,7 @@ sal_Bool WatchTreeListBox::EditingEntry( SvLBoxEntry* pEntry, Selection& )
if( !pItem->mpObject && (pItem->mpArray == NULL || pItem->nDimLevel == pItem->nDimCount) )
{
aEditingRes = SvHeaderTabListBox::GetEntryText( pEntry, ITEM_ID_VALUE-1 );
- aEditingRes.EraseLeadingChars();
- aEditingRes.EraseTrailingChars();
+ aEditingRes = comphelper::string::strip(aEditingRes, ' ');
bEdit = sal_True;
}
}
@@ -1966,9 +1964,7 @@ sal_Bool WatchTreeListBox::EditedEntry( SvLBoxEntry* pEntry, const rtl::OUString
WatchItem* pItem = (WatchItem*)pEntry->GetUserData();
String aVName( pItem->maName );
- String aResult = rNewText;
- aResult.EraseLeadingChars();
- aResult.EraseTrailingChars();
+ String aResult = comphelper::string::strip(rNewText, ' ');
sal_uInt16 nResultLen = aResult.Len();
sal_Unicode cFirst = aResult.GetChar( 0 );