summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--extensions/source/propctrlr/standardcontrol.cxx2
-rw-r--r--include/vcl/edit.hxx2
-rw-r--r--vcl/source/control/edit.cxx24
3 files changed, 14 insertions, 14 deletions
diff --git a/extensions/source/propctrlr/standardcontrol.cxx b/extensions/source/propctrlr/standardcontrol.cxx
index 06bf36dea221..064271a670ac 100644
--- a/extensions/source/propctrlr/standardcontrol.cxx
+++ b/extensions/source/propctrlr/standardcontrol.cxx
@@ -384,7 +384,7 @@ namespace pcr
//--------------------------------------------------------------------
bool HyperlinkInput::impl_textHitTest( const ::Point& _rWindowPos )
{
- xub_StrLen nPos = GetCharPos( _rWindowPos );
+ sal_Int32 nPos = GetCharPos( _rWindowPos );
return ( ( nPos != STRING_LEN ) && ( nPos < GetText().getLength() ) );
}
diff --git a/include/vcl/edit.hxx b/include/vcl/edit.hxx
index f02879b3b998..a5f77577139a 100644
--- a/include/vcl/edit.hxx
+++ b/include/vcl/edit.hxx
@@ -236,7 +236,7 @@ public:
virtual Size CalcSize( sal_uInt16 nChars ) const;
virtual xub_StrLen GetMaxVisChars() const;
- xub_StrLen GetCharPos( const Point& rWindowPos ) const;
+ sal_Int32 GetCharPos( const Point& rWindowPos ) const;
// shows a warning box saying "text too long, truncated"
static void ShowTruncationWarning( Window* pParent );
diff --git a/vcl/source/control/edit.cxx b/vcl/source/control/edit.cxx
index 904a502ef501..d9d17ae52dc7 100644
--- a/vcl/source/control/edit.cxx
+++ b/vcl/source/control/edit.cxx
@@ -1430,7 +1430,7 @@ void Edit::MouseButtonDown( const MouseEvent& rMEvt )
return;
}
- xub_StrLen nChar = ImplGetCharPos( rMEvt.GetPosPixel() );
+ sal_Int32 nCharPos = ImplGetCharPos( rMEvt.GetPosPixel() );
Selection aSelection( maSelection );
aSelection.Justify();
@@ -1451,10 +1451,10 @@ void Edit::MouseButtonDown( const MouseEvent& rMEvt )
ImplSetSelection( Selection( aBoundary.startPos, aBoundary.endPos ) );
ImplCopyToSelectionClipboard();
}
- else if ( !rMEvt.IsShift() && HasFocus() && aSelection.IsInside( nChar ) )
+ else if ( !rMEvt.IsShift() && HasFocus() && aSelection.IsInside( nCharPos ) )
mbClickedInSelection = sal_True;
else if ( rMEvt.IsLeft() )
- ImplSetCursorPos( nChar, rMEvt.IsShift() );
+ ImplSetCursorPos( nCharPos, rMEvt.IsShift() );
if ( !mbClickedInSelection && rMEvt.IsLeft() && ( rMEvt.GetClicks() == 1 ) )
StartTracking( STARTTRACK_SCROLLREPEAT );
@@ -1471,8 +1471,8 @@ void Edit::MouseButtonUp( const MouseEvent& rMEvt )
{
if ( mbClickedInSelection && rMEvt.IsLeft() )
{
- xub_StrLen nChar = ImplGetCharPos( rMEvt.GetPosPixel() );
- ImplSetCursorPos( nChar, sal_False );
+ sal_Int32 nCharPos = ImplGetCharPos( rMEvt.GetPosPixel() );
+ ImplSetCursorPos( nCharPos, sal_False );
mbClickedInSelection = sal_False;
}
else if ( rMEvt.IsMiddle() && !mbReadOnly &&
@@ -1492,8 +1492,8 @@ void Edit::Tracking( const TrackingEvent& rTEvt )
{
if ( mbClickedInSelection )
{
- xub_StrLen nChar = ImplGetCharPos( rTEvt.GetMouseEvent().GetPosPixel() );
- ImplSetCursorPos( nChar, sal_False );
+ sal_Int32 nCharPos = ImplGetCharPos( rTEvt.GetMouseEvent().GetPosPixel() );
+ ImplSetCursorPos( nCharPos, sal_False );
mbClickedInSelection = sal_False;
}
else if ( rTEvt.GetMouseEvent().IsLeft() )
@@ -1505,8 +1505,8 @@ void Edit::Tracking( const TrackingEvent& rTEvt )
{
if( !mbClickedInSelection )
{
- xub_StrLen nChar = ImplGetCharPos( rTEvt.GetMouseEvent().GetPosPixel() );
- ImplSetCursorPos( nChar, sal_True );
+ sal_Int32 nCharPos = ImplGetCharPos( rTEvt.GetMouseEvent().GetPosPixel() );
+ ImplSetCursorPos( nCharPos, sal_True );
}
}
@@ -2967,7 +2967,7 @@ xub_StrLen Edit::GetMaxVisChars() const
// -----------------------------------------------------------------------
-xub_StrLen Edit::GetCharPos( const Point& rWindowPos ) const
+sal_Int32 Edit::GetCharPos( const Point& rWindowPos ) const
{
return ImplGetCharPos( rWindowPos );
}
@@ -3033,8 +3033,8 @@ void Edit::dragGestureRecognized( const ::com::sun::star::datatransfer::dnd::Dra
// Nur wenn Maus in der Selektion...
Point aMousePos( rDGE.DragOriginX, rDGE.DragOriginY );
- xub_StrLen nChar = ImplGetCharPos( aMousePos );
- if ( (nChar >= aSel.Min()) && (nChar < aSel.Max()) )
+ sal_Int32 nCharPos = ImplGetCharPos( aMousePos );
+ if ( (nCharPos >= aSel.Min()) && (nCharPos < aSel.Max()) )
{
if ( !mpDDInfo )
mpDDInfo = new DDInfo;