Kaydet (Commit) 8f3ca2e6 authored tarafından Noel Grandin's avatar Noel Grandin

tdf#113422 Crash in: ScPreview::MouseMove(MouseEvent const &)

regression from

    commit 0ad8447d
    dyncolcontainer: convert nRight to std::vector

Change-Id: I9cdf80115a2be73ec2b30fd875a904de3333fddf
Reviewed-on: https://gerrit.libreoffice.org/43905Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 4f5ef175
...@@ -1358,7 +1358,8 @@ void ScPreview::MouseMove( const MouseEvent& rMEvt ) ...@@ -1358,7 +1358,8 @@ void ScPreview::MouseMove( const MouseEvent& rMEvt )
{ {
Point aColumnTop = LogicToPixel( Point( 0, -aOffset.Y() ) ,aMMMode ); Point aColumnTop = LogicToPixel( Point( 0, -aOffset.Y() ) ,aMMMode );
Point aColumnBottom = LogicToPixel( Point( 0, (long)( nHeight * HMM_PER_TWIPS - aOffset.Y()) ), aMMMode ); Point aColumnBottom = LogicToPixel( Point( 0, (long)( nHeight * HMM_PER_TWIPS - aOffset.Y()) ), aMMMode );
if( aPixPt.X() < ( mvRight[i] + 2 ) && ( aPixPt.X() > ( mvRight[i] - 2 ) ) && ( aPixPt.X() < aRightTop.X() ) && ( aPixPt.X() > aLeftTop.X() ) long nRight = i < static_cast<SCCOL>(mvRight.size()) ? mvRight[i] : 0;
if( aPixPt.X() < ( nRight + 2 ) && ( aPixPt.X() > ( nRight - 2 ) ) && ( aPixPt.X() < aRightTop.X() ) && ( aPixPt.X() > aLeftTop.X() )
&& ( aPixPt.Y() > aColumnTop.Y() ) && ( aPixPt.Y() < aColumnBottom.Y() ) && !bLeftRulerMove && !bRightRulerMove && ( aPixPt.Y() > aColumnTop.Y() ) && ( aPixPt.Y() < aColumnBottom.Y() ) && !bLeftRulerMove && !bRightRulerMove
&& !bTopRulerMove && !bBottomRulerMove && !bHeaderRulerMove && !bFooterRulerMove ) && !bTopRulerMove && !bBottomRulerMove && !bHeaderRulerMove && !bFooterRulerMove )
{ {
......
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