summaryrefslogtreecommitdiff
path: root/sc/source/ui/view/gridwin.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-05-06 10:14:38 +0200
committerJochen Nitschke <j.nitschke+logerrit@ok.de>2016-05-07 12:24:31 +0000
commit9613b493172fe9aa8efd9c9c090f82ca2e89cf21 (patch)
tree3cc0d212aea1de270160e295a70c9f08f2e84334 /sc/source/ui/view/gridwin.cxx
parent464348e82d8cbb0a6d3e5638da3f737f3e6f2d00 (diff)
clang-tidy modernize-loop-convert in sc
Change-Id: I620028d69b11ea0469efd7b02ac7bbc7edab1066 Reviewed-on: https://gerrit.libreoffice.org/24690 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
Diffstat (limited to 'sc/source/ui/view/gridwin.cxx')
-rw-r--r--sc/source/ui/view/gridwin.cxx17
1 files changed, 7 insertions, 10 deletions
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index e781d5acd462..0abbfa970629 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -6023,10 +6023,9 @@ void ScGridWindow::UpdateCursorOverlay()
std::vector< basegfx::B2DRange > aRanges;
const basegfx::B2DHomMatrix aTransform(GetInverseViewTransformation());
- for(size_t a(0); a < aPixelRects.size(); a++)
+ for(const Rectangle & rRA : aPixelRects)
{
- const Rectangle aRA(aPixelRects[a]);
- basegfx::B2DRange aRB(aRA.Left(), aRA.Top(), aRA.Right() + 1, aRA.Bottom() + 1);
+ basegfx::B2DRange aRB(rRA.Left(), rRA.Top(), rRA.Right() + 1, rRA.Bottom() + 1);
aRB.transform(aTransform);
aRanges.push_back(aRB);
}
@@ -6087,18 +6086,17 @@ void ScGridWindow::UpdateSelectionOverlay()
SCTAB nTab = pViewData->GetTabNo();
bool bLayoutRTL = pDoc->IsLayoutRTL( nTab );
- for(size_t a(0); a < aPixelRects.size(); a++)
+ for(const Rectangle & rRA : aPixelRects)
{
- const Rectangle aRA(aPixelRects[a]);
if (bLayoutRTL)
{
- basegfx::B2DRange aRB(aRA.Left(), aRA.Top() - 1, aRA.Right() + 1, aRA.Bottom());
+ basegfx::B2DRange aRB(rRA.Left(), rRA.Top() - 1, rRA.Right() + 1, rRA.Bottom());
aRB.transform(aTransform);
aRanges.push_back(aRB);
}
else
{
- basegfx::B2DRange aRB(aRA.Left() - 1, aRA.Top() - 1, aRA.Right(), aRA.Bottom());
+ basegfx::B2DRange aRB(rRA.Left() - 1, rRA.Top() - 1, rRA.Right(), rRA.Bottom());
aRB.transform(aTransform);
aRanges.push_back(aRB);
}
@@ -6324,10 +6322,9 @@ void ScGridWindow::UpdateDragRectOverlay()
std::vector< basegfx::B2DRange > aRanges;
const basegfx::B2DHomMatrix aTransform(GetInverseViewTransformation());
- for(size_t a(0); a < aPixelRects.size(); a++)
+ for(const Rectangle & rRA : aPixelRects)
{
- const Rectangle aRA(aPixelRects[a]);
- basegfx::B2DRange aRB(aRA.Left(), aRA.Top(), aRA.Right() + 1, aRA.Bottom() + 1);
+ basegfx::B2DRange aRB(rRA.Left(), rRA.Top(), rRA.Right() + 1, rRA.Bottom() + 1);
aRB.transform(aTransform);
aRanges.push_back(aRB);
}