summaryrefslogtreecommitdiff
path: root/drawinglayer/source/primitive3d
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@collabora.co.uk>2024-03-07 12:08:09 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2024-03-07 12:53:27 +0100
commit7979508e4328ceb9d6a2dff6a2a080ea64247c7e (patch)
tree3f3b9bfd3c02fbbcf2b6f623828fa3cfedf6e5d5 /drawinglayer/source/primitive3d
parent10e12d0e6316ac20388f589f062e784e8d9aa630 (diff)
Simplify some basegfx::fTools::*orEqual calls
Comparing with zero is simple - the implementation of basegfx::fTools::moreOrEqual calls rtl_math_approxEqual eventually, which special-zases zero. Change-Id: I62f10f63f103d91a201dfeb20e5b3f9010f377c1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164526 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'drawinglayer/source/primitive3d')
-rw-r--r--drawinglayer/source/primitive3d/sdrextrudeprimitive3d.cxx4
-rw-r--r--drawinglayer/source/primitive3d/sdrlatheprimitive3d.cxx4
2 files changed, 4 insertions, 4 deletions
diff --git a/drawinglayer/source/primitive3d/sdrextrudeprimitive3d.cxx b/drawinglayer/source/primitive3d/sdrextrudeprimitive3d.cxx
index 34f4d8472284..ed0e8d41c4ab 100644
--- a/drawinglayer/source/primitive3d/sdrextrudeprimitive3d.cxx
+++ b/drawinglayer/source/primitive3d/sdrextrudeprimitive3d.cxx
@@ -410,13 +410,13 @@ namespace drawinglayer::primitive3d
mbCloseBack(bCloseBack)
{
// make sure depth is positive
- if(basegfx::fTools::lessOrEqual(getDepth(), 0.0))
+ if(getDepth() <= 0.0)
{
mfDepth = 0.0;
}
// make sure the percentage value getDiagonal() is between 0.0 and 1.0
- if(basegfx::fTools::lessOrEqual(getDiagonal(), 0.0))
+ if(getDiagonal() <= 0.0)
{
mfDiagonal = 0.0;
}
diff --git a/drawinglayer/source/primitive3d/sdrlatheprimitive3d.cxx b/drawinglayer/source/primitive3d/sdrlatheprimitive3d.cxx
index ca6e11eec4d4..682ea0c54042 100644
--- a/drawinglayer/source/primitive3d/sdrlatheprimitive3d.cxx
+++ b/drawinglayer/source/primitive3d/sdrlatheprimitive3d.cxx
@@ -266,13 +266,13 @@ namespace drawinglayer::primitive3d
mbCloseBack(bCloseBack)
{
// make sure Rotation is positive
- if(basegfx::fTools::lessOrEqual(getRotation(), 0.0))
+ if(getRotation() <= 0.0)
{
mfRotation = 0.0;
}
// make sure the percentage value getDiagonal() is between 0.0 and 1.0
- if(basegfx::fTools::lessOrEqual(getDiagonal(), 0.0))
+ if(getDiagonal() <= 0.0)
{
mfDiagonal = 0.0;
}