summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-01-13 11:50:56 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-01-13 11:50:56 +0000
commit57ec4a841a9bb5c0db2f6eeb7aa5a6bde98de008 (patch)
treeb102d3f57ad78abba7e11ac124973c62d979eca9 /vcl
parent62b2451a1dff3b91c23a7083dbf6252984ee3d29 (diff)
longparas: drop xub_StrLen from fields
Change-Id: Icd6dbc9b374df3e528dc22afa07be72d7fc89ca7
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/control/field2.cxx20
1 files changed, 10 insertions, 10 deletions
diff --git a/vcl/source/control/field2.cxx b/vcl/source/control/field2.cxx
index 2107bd9d6f66..585f81a7f759 100644
--- a/vcl/source/control/field2.cxx
+++ b/vcl/source/control/field2.cxx
@@ -321,7 +321,7 @@ static OUString ImplPatternReformat( const OUString& rStr,
static void ImplPatternMaxPos( const OUString& rStr, const OString& rEditMask,
sal_uInt16 nFormatFlags, bool bSameMask,
- sal_uInt16 nCursorPos, sal_Int32& rPos )
+ sal_Int32 nCursorPos, sal_Int32& rPos )
{
// last position must not be longer than the contained string
@@ -394,7 +394,7 @@ static void ImplPatternProcessStrictModify( Edit* pEdit,
if ( nMaxSel >= aText.getLength() )
{
sal_Int32 nMaxPos = aNewText.getLength();
- ImplPatternMaxPos( aNewText, rEditMask, nFormatFlags, bSameMask, (xub_StrLen)nMaxSel, nMaxPos );
+ ImplPatternMaxPos( aNewText, rEditMask, nFormatFlags, bSameMask, nMaxSel, nMaxPos );
if ( aSel.Min() == aSel.Max() )
{
aSel.Min() = nMaxPos;
@@ -409,11 +409,11 @@ static void ImplPatternProcessStrictModify( Edit* pEdit,
}
}
-static xub_StrLen ImplPatternLeftPos(const OString& rEditMask, sal_Int32 nCursorPos)
+static sal_Int32 ImplPatternLeftPos(const OString& rEditMask, sal_Int32 nCursorPos)
{
// search non-literal predecessor
- xub_StrLen nNewPos = nCursorPos;
- xub_StrLen nTempPos = nNewPos;
+ sal_Int32 nNewPos = nCursorPos;
+ sal_Int32 nTempPos = nNewPos;
while ( nTempPos )
{
if ( rEditMask[nTempPos-1] != EDITMASK_LITERAL )
@@ -426,7 +426,7 @@ static xub_StrLen ImplPatternLeftPos(const OString& rEditMask, sal_Int32 nCursor
return nNewPos;
}
-static xub_StrLen ImplPatternRightPos( const OUString& rStr, const OString& rEditMask,
+static sal_Int32 ImplPatternRightPos( const OUString& rStr, const OString& rEditMask,
sal_uInt16 nFormatFlags, bool bSameMask,
sal_Int32 nCursorPos )
{
@@ -482,7 +482,7 @@ static bool ImplPatternProcessKeyInput( Edit* pEdit, const KeyEvent& rKEvt,
// all was selected by the focus
Selection aSel( aOldSel );
aSel.Justify();
- nCursorPos = (xub_StrLen)aSel.Min();
+ nCursorPos = aSel.Min();
aSel.Max() = ImplPatternRightPos( pEdit->GetText(), rEditMask, nFormatFlags, bSameMask, nCursorPos );
if ( bShift )
aSel.Min() = aOldSel.Min();
@@ -605,7 +605,7 @@ static bool ImplPatternProcessKeyInput( Edit* pEdit, const KeyEvent& rKEvt,
Selection aSel = aOldSel;
aSel.Justify();
- nNewPos = (xub_StrLen)aSel.Min();
+ nNewPos = aSel.Min();
if ( nNewPos < rEditMask.getLength() )
{
@@ -669,7 +669,7 @@ static bool ImplPatternProcessKeyInput( Edit* pEdit, const KeyEvent& rKEvt,
aStr.truncate( n );
if ( aSel.Len() )
- aStr.remove( (xub_StrLen)aSel.Min(), (xub_StrLen)aSel.Len() );
+ aStr.remove( aSel.Min(), aSel.Len() );
if ( aStr.getLength() < rEditMask.getLength() )
{
@@ -690,7 +690,7 @@ static bool ImplPatternProcessKeyInput( Edit* pEdit, const KeyEvent& rKEvt,
if ( aSel.Len() )
{
// delete selection
- OUString aRep = rLiteralMask.copy( (xub_StrLen)aSel.Min(), (xub_StrLen)aSel.Len() );
+ OUString aRep = rLiteralMask.copy( aSel.Min(), aSel.Len() );
aStr.remove( aSel.Min(), aRep.getLength() );
aStr.insert( aSel.Min(), aRep );
}