Revert "use fmod and make code simpler"
This reverts commit 66ef9bc4aa0d0bd364d20373360ad2361394a871.
diff --git a/chart2/source/view/main/DummyXShape.cxx b/chart2/source/view/main/DummyXShape.cxx
index d7dcf1d..44da917 100644
--- a/chart2/source/view/main/DummyXShape.cxx
+++ b/chart2/source/view/main/DummyXShape.cxx
@@ -351,8 +351,9 @@ void DummyPieSegment2D::render()
{
DummyChart* pChart = getRootShape();
mfUnitCircleWidthAngleDegree = std::fmod(mfUnitCircleWidthAngleDegree, 360.0);
if(mfUnitCircleWidthAngleDegree)
while(mfUnitCircleWidthAngleDegree>360)
mfUnitCircleWidthAngleDegree -= 360.0;
while(mfUnitCircleWidthAngleDegree<0)
mfUnitCircleWidthAngleDegree += 360.0;
pChart->m_GLRender.GeneratePieSegment2D(mfUnitCircleInnerRadius, mfUnitCircleOuterRadius,