sc/source/ui/view/tabview2.cxx | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-)
New commits: commit b5c191c130a132fb5f80ce9eefe4e98f1ad9422f Author: Dennis Francis <dennisfrancis...@gmail.com> Date: Mon Jan 18 06:47:02 2016 +0530 Fix for tdf#97084 : Scroll view to the ref boundary... ...but maintain the fix for tdf#96524 Change-Id: I35128843d13904e9e0cf9ded559c352acb3c7c46 Reviewed-on: https://gerrit.libreoffice.org/21559 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Eike Rathke <er...@redhat.com> Tested-by: Eike Rathke <er...@redhat.com> diff --git a/sc/source/ui/view/tabview2.cxx b/sc/source/ui/view/tabview2.cxx index 7ccf861..556390d 100644 --- a/sc/source/ui/view/tabview2.cxx +++ b/sc/source/ui/view/tabview2.cxx @@ -912,9 +912,19 @@ void ScTabView::ExpandBlock(SCsCOL nMovX, SCsROW nMovY, ScFollowMode eMode) pDoc->SkipOverlapped(nNewX, nNewY, nRefTab); UpdateRef(nNewX, nNewY, nRefTab); - if ((aViewData.GetRefStartX() == MAXCOL || nNewX != MAXCOL) && - (aViewData.GetRefStartY() == MAXROW || nNewY != MAXROW)) - AlignToCursor(nNewX, nNewY, eMode); + SCCOL nTargetCol = nNewX; + SCROW nTargetRow = nNewY; + if (((aViewData.GetRefStartX() == 0) || (aViewData.GetRefStartY() == 0)) && + ((nNewX != MAXCOL) || (nNewY != MAXROW))) + { + // Row selection + if ((aViewData.GetRefStartX() == 0) && (nNewX == MAXCOL)) + nTargetCol = aViewData.GetCurX(); + // Column selection + if ((aViewData.GetRefStartY() == 0) && (nNewY == MAXROW)) + nTargetRow = aViewData.GetCurY(); + } + AlignToCursor(nTargetCol, nTargetRow, eMode); } else { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits