summaryrefslogtreecommitdiff
path: root/basegfx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-07-06 14:49:15 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-07-10 09:57:24 +0200
commit4250b25c6ae361359300ab6ccde27230f8e01039 (patch)
tree916a8420282928a92ede0760d696997550ae0840 /basegfx
parent2ed9a2b641682d8612b5404bd3978ed049aa0266 (diff)
teach unnecessaryparen loplugin about identifiers
Change-Id: I5710b51e53779c222cec0bf08cd34bda330fec4b Reviewed-on: https://gerrit.libreoffice.org/39737 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'basegfx')
-rw-r--r--basegfx/source/polygon/b2dpolygontools.cxx10
-rw-r--r--basegfx/source/polygon/b3dpolypolygontools.cxx8
-rw-r--r--basegfx/source/raster/rasterconvert3d.cxx2
3 files changed, 10 insertions, 10 deletions
diff --git a/basegfx/source/polygon/b2dpolygontools.cxx b/basegfx/source/polygon/b2dpolygontools.cxx
index 14276926db69..80f3da07d50b 100644
--- a/basegfx/source/polygon/b2dpolygontools.cxx
+++ b/basegfx/source/polygon/b2dpolygontools.cxx
@@ -573,7 +573,7 @@ namespace basegfx
{
// if fDistance >= fLength decrement with multiple of fLength
sal_uInt32 nCount(sal_uInt32(fDistance / fLength));
- fDistance -= (double)(nCount) * fLength;
+ fDistance -= (double)nCount * fLength;
}
else
{
@@ -2444,10 +2444,10 @@ namespace basegfx
const double fRelativeY((rCandidate.getY() - rOriginal.getMinY()) / rOriginal.getHeight());
const double fOneMinusRelativeX(1.0 - fRelativeX);
const double fOneMinusRelativeY(1.0 - fRelativeY);
- const double fNewX((fOneMinusRelativeY) * ((fOneMinusRelativeX) * rTopLeft.getX() + fRelativeX * rTopRight.getX()) +
- fRelativeY * ((fOneMinusRelativeX) * rBottomLeft.getX() + fRelativeX * rBottomRight.getX()));
- const double fNewY((fOneMinusRelativeX) * ((fOneMinusRelativeY) * rTopLeft.getY() + fRelativeY * rBottomLeft.getY()) +
- fRelativeX * ((fOneMinusRelativeY) * rTopRight.getY() + fRelativeY * rBottomRight.getY()));
+ const double fNewX(fOneMinusRelativeY * (fOneMinusRelativeX * rTopLeft.getX() + fRelativeX * rTopRight.getX()) +
+ fRelativeY * (fOneMinusRelativeX * rBottomLeft.getX() + fRelativeX * rBottomRight.getX()));
+ const double fNewY(fOneMinusRelativeX * (fOneMinusRelativeY * rTopLeft.getY() + fRelativeY * rBottomLeft.getY()) +
+ fRelativeX * (fOneMinusRelativeY * rTopRight.getY() + fRelativeY * rBottomRight.getY()));
return B2DPoint(fNewX, fNewY);
}
diff --git a/basegfx/source/polygon/b3dpolypolygontools.cxx b/basegfx/source/polygon/b3dpolypolygontools.cxx
index c147df888ac8..04408dee4721 100644
--- a/basegfx/source/polygon/b3dpolypolygontools.cxx
+++ b/basegfx/source/polygon/b3dpolypolygontools.cxx
@@ -267,12 +267,12 @@ namespace basegfx
for(a = nLoopVerInit; a < nLoopVerLimit; a++)
{
- const double fVer(fVerStart + ((double)(a) * fVerDiffPerStep));
+ const double fVer(fVerStart + ((double)a * fVerDiffPerStep));
B3DPolygon aNew;
for(b = 0; b < nLoopHorLimit; b++)
{
- const double fHor(fHorStart + ((double)(b) * fHorDiffPerStep));
+ const double fHor(fHorStart + ((double)b * fHorDiffPerStep));
aNew.append(getPointFromCartesian(fHor, fVer));
}
@@ -283,7 +283,7 @@ namespace basegfx
// create vertical half-rings
for(a = 0; a < nLoopHorLimit; a++)
{
- const double fHor(fHorStart + ((double)(a) * fHorDiffPerStep));
+ const double fHor(fHorStart + ((double)a * fHorDiffPerStep));
B3DPolygon aNew;
if(bVerFromTop)
@@ -293,7 +293,7 @@ namespace basegfx
for(b = nLoopVerInit; b < nLoopVerLimit; b++)
{
- const double fVer(fVerStart + ((double)(b) * fVerDiffPerStep));
+ const double fVer(fVerStart + ((double)b * fVerDiffPerStep));
aNew.append(getPointFromCartesian(fHor, fVer));
}
diff --git a/basegfx/source/raster/rasterconvert3d.cxx b/basegfx/source/raster/rasterconvert3d.cxx
index 859ed47721e8..951cdbd65ebd 100644
--- a/basegfx/source/raster/rasterconvert3d.cxx
+++ b/basegfx/source/raster/rasterconvert3d.cxx
@@ -101,7 +101,7 @@ namespace basegfx
aCurrentEntry->incrementRasterConversionLineEntry3D(nStep, *this);
}
- aCurrentLine.push_back(&(*(aCurrentEntry)));
+ aCurrentLine.push_back(&(*aCurrentEntry));
}
}