[Libreoffice-commits] core.git: chart2/source
Noel Grandin
noel at peralex.com
Fri Nov 20 02:41:59 PST 2015
chart2/source/view/charttypes/AreaChart.cxx | 2 +-
chart2/source/view/charttypes/BarChart.cxx | 2 +-
chart2/source/view/charttypes/BubbleChart.cxx | 6 +++---
chart2/source/view/charttypes/GL3DBarChart.cxx | 9 +++------
chart2/source/view/charttypes/NetChart.cxx | 2 +-
chart2/source/view/inc/GL3DBarChart.hxx | 5 +----
chart2/source/view/inc/GL3DRenderer.hxx | 3 ---
chart2/source/view/inc/LabelPositionHelper.hxx | 4 +---
chart2/source/view/main/LabelPositionHelper.cxx | 6 ++----
chart2/source/view/main/OpenGLRender.hxx | 2 --
chart2/source/view/main/PolarLabelPositionHelper.cxx | 2 +-
11 files changed, 14 insertions(+), 29 deletions(-)
New commits:
commit c79b7fd8d4e6e029cf8e6bfb2c7e10b52a4d5781
Author: Noel Grandin <noel at peralex.com>
Date: Fri Nov 20 12:41:00 2015 +0200
loplugin:unusedfields in chart2
Change-Id: I7da22cc193d9fadf9a3b5dc1453f5574d2357c31
diff --git a/chart2/source/view/charttypes/AreaChart.cxx b/chart2/source/view/charttypes/AreaChart.cxx
index 577aec3..3fe22b7 100644
--- a/chart2/source/view/charttypes/AreaChart.cxx
+++ b/chart2/source/view/charttypes/AreaChart.cxx
@@ -977,7 +977,7 @@ void AreaChart::createShapes()
{
if(LABEL_ALIGN_CENTER==eAlignment || m_nDimension == 3 )
nOffset = 0;
- aScreenPosition2D = awt::Point( LabelPositionHelper(pPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory)
+ aScreenPosition2D = awt::Point( LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory)
.transformSceneToScreenPosition( aScenePosition3D ) );
}
diff --git a/chart2/source/view/charttypes/BarChart.cxx b/chart2/source/view/charttypes/BarChart.cxx
index 9160133..cd2019e 100644
--- a/chart2/source/view/charttypes/BarChart.cxx
+++ b/chart2/source/view/charttypes/BarChart.cxx
@@ -263,7 +263,7 @@ awt::Point BarChart::getLabelScreenPositionAndAlignment(
drawing::Position3D aScenePosition3D( pPosHelper->
transformScaledLogicToScene( fX, fY, fZ, true ) );
- return LabelPositionHelper(pPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory)
+ return LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory)
.transformSceneToScreenPosition( aScenePosition3D );
}
diff --git a/chart2/source/view/charttypes/BubbleChart.cxx b/chart2/source/view/charttypes/BubbleChart.cxx
index 2adc03c..11004bb 100644
--- a/chart2/source/view/charttypes/BubbleChart.cxx
+++ b/chart2/source/view/charttypes/BubbleChart.cxx
@@ -109,8 +109,8 @@ void BubbleChart::calculateBubbleSizeScalingFactor()
drawing::Position3D aSceneMinPos( m_pMainPosHelper->transformLogicToScene( m_pMainPosHelper->getLogicMinX(),m_pMainPosHelper->getLogicMinY(),fLogicZ, false ) );
drawing::Position3D aSceneMaxPos( m_pMainPosHelper->transformLogicToScene( m_pMainPosHelper->getLogicMaxX(),m_pMainPosHelper->getLogicMaxY(),fLogicZ, false ) );
- awt::Point aScreenMinPos( LabelPositionHelper(m_pMainPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory).transformSceneToScreenPosition( aSceneMinPos ) );
- awt::Point aScreenMaxPos( LabelPositionHelper(m_pMainPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory).transformSceneToScreenPosition( aSceneMaxPos ) );
+ awt::Point aScreenMinPos( LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory).transformSceneToScreenPosition( aSceneMinPos ) );
+ awt::Point aScreenMaxPos( LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory).transformSceneToScreenPosition( aSceneMaxPos ) );
sal_Int32 nWidth = abs( aScreenMaxPos.X - aScreenMinPos.X );
sal_Int32 nHeight = abs( aScreenMaxPos.Y - aScreenMinPos.Y );
@@ -380,7 +380,7 @@ void BubbleChart::createShapes()
break;
}
- awt::Point aScreenPosition2D( LabelPositionHelper(pPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory)
+ awt::Point aScreenPosition2D( LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory)
.transformSceneToScreenPosition( aScenePosition3D ) );
sal_Int32 nOffset = 0;
if(LABEL_ALIGN_CENTER!=eAlignment)
diff --git a/chart2/source/view/charttypes/GL3DBarChart.cxx b/chart2/source/view/charttypes/GL3DBarChart.cxx
index b685a68..4f92b2a 100644
--- a/chart2/source/view/charttypes/GL3DBarChart.cxx
+++ b/chart2/source/view/charttypes/GL3DBarChart.cxx
@@ -575,12 +575,9 @@ GL3DBarChart::GL3DBarChart(
mpWindow->getContext().resetCurrent();
}
-GL3DBarChart::BarInformation::BarInformation(const glm::vec3& rPos, float nVal,
- sal_Int32 nIndex, sal_Int32 nSeriesIndex):
+GL3DBarChart::BarInformation::BarInformation(const glm::vec3& rPos, float nVal):
maPos(rPos),
- mnVal(nVal),
- mnIndex(nIndex),
- mnSeriesIndex(nSeriesIndex)
+ mnVal(nVal)
{
}
@@ -711,7 +708,7 @@ void GL3DBarChart::create3DShapes(const std::vector<std::unique_ptr<VDataSeries>
maBarMap.insert(std::pair<sal_uInt32, BarInformation>(nId,
BarInformation(glm::vec3(nXPos, nYPos, float(nVal/nMaxVal)),
- nVal, nIndex, nSeriesIndex)));
+ nVal)));
recordBarHistory(nId, nVal);
if (mbBenchMarkMode)
{
diff --git a/chart2/source/view/charttypes/NetChart.cxx b/chart2/source/view/charttypes/NetChart.cxx
index d1bd56c..3f971b2 100644
--- a/chart2/source/view/charttypes/NetChart.cxx
+++ b/chart2/source/view/charttypes/NetChart.cxx
@@ -671,7 +671,7 @@ void NetChart::createShapes()
{
if(LABEL_ALIGN_CENTER==eAlignment )
nOffset = 0;
- aScreenPosition2D = awt::Point( LabelPositionHelper(pPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory)
+ aScreenPosition2D = awt::Point( LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory)
.transformSceneToScreenPosition( aScenePosition3D ) );
}
diff --git a/chart2/source/view/inc/GL3DBarChart.hxx b/chart2/source/view/inc/GL3DBarChart.hxx
index 419c679..417160a 100644
--- a/chart2/source/view/inc/GL3DBarChart.hxx
+++ b/chart2/source/view/inc/GL3DBarChart.hxx
@@ -151,11 +151,8 @@ private:
{
glm::vec3 maPos;
float mnVal;
- sal_Int32 mnIndex;
- sal_Int32 mnSeriesIndex;
- BarInformation(const glm::vec3& rPos, float nVal,
- sal_Int32 nIndex, sal_Int32 nSeriesIndex);
+ BarInformation(const glm::vec3& rPos, float nVal);
};
std::map<sal_uInt32, const BarInformation> maBarMap;
diff --git a/chart2/source/view/inc/GL3DRenderer.hxx b/chart2/source/view/inc/GL3DRenderer.hxx
index 8316806..2c8008d 100644
--- a/chart2/source/view/inc/GL3DRenderer.hxx
+++ b/chart2/source/view/inc/GL3DRenderer.hxx
@@ -59,9 +59,6 @@ struct LightSource
glm::vec4 lightColor;
glm::vec4 positionWorldspace;
float lightPower;
- float pad1;
- float pad2;
- float pad3;
};
struct GlobalLights
diff --git a/chart2/source/view/inc/LabelPositionHelper.hxx b/chart2/source/view/inc/LabelPositionHelper.hxx
index dc4659c..82f50da 100644
--- a/chart2/source/view/inc/LabelPositionHelper.hxx
+++ b/chart2/source/view/inc/LabelPositionHelper.hxx
@@ -38,8 +38,7 @@ class LabelPositionHelper
{
public:
LabelPositionHelper(
- PlottingPositionHelper* pPosHelper
- , sal_Int32 nDimensionCount
+ sal_Int32 nDimensionCount
, const ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShapes >& xLogicTarget
, AbstractShapeFactory* pShapeFactory );
virtual ~LabelPositionHelper();
@@ -59,7 +58,6 @@ private:
LabelPositionHelper();
protected:
- PlottingPositionHelper* m_pPosHelper;
sal_Int32 m_nDimensionCount;
private:
diff --git a/chart2/source/view/main/LabelPositionHelper.cxx b/chart2/source/view/main/LabelPositionHelper.cxx
index d1faa2e..84c279d 100644
--- a/chart2/source/view/main/LabelPositionHelper.cxx
+++ b/chart2/source/view/main/LabelPositionHelper.cxx
@@ -33,12 +33,10 @@ using namespace ::com::sun::star;
using namespace ::com::sun::star::chart2;
LabelPositionHelper::LabelPositionHelper(
- PlottingPositionHelper* pPosHelper
- , sal_Int32 nDimensionCount
+ sal_Int32 nDimensionCount
, const uno::Reference< drawing::XShapes >& xLogicTarget
, AbstractShapeFactory* pShapeFactory )
- : m_pPosHelper(pPosHelper)
- , m_nDimensionCount(nDimensionCount)
+ : m_nDimensionCount(nDimensionCount)
, m_xLogicTarget(xLogicTarget)
, m_pShapeFactory(pShapeFactory)
{
diff --git a/chart2/source/view/main/OpenGLRender.hxx b/chart2/source/view/main/OpenGLRender.hxx
index dae190a..5339eb1 100644
--- a/chart2/source/view/main/OpenGLRender.hxx
+++ b/chart2/source/view/main/OpenGLRender.hxx
@@ -187,8 +187,6 @@ private:
float m_BackgroundColor[16];
std::list <PointList> m_PieSegment2DShapePointList;
- PointList m_Symbol2DPointList;
- std::list<PointList> m_Symbol2DShapePointList;
GLuint m_SymbolProID;
GLuint m_SymbolVertexID;
diff --git a/chart2/source/view/main/PolarLabelPositionHelper.cxx b/chart2/source/view/main/PolarLabelPositionHelper.cxx
index b6053cb..eefa339 100644
--- a/chart2/source/view/main/PolarLabelPositionHelper.cxx
+++ b/chart2/source/view/main/PolarLabelPositionHelper.cxx
@@ -35,7 +35,7 @@ PolarLabelPositionHelper::PolarLabelPositionHelper(
, sal_Int32 nDimensionCount
, const uno::Reference< drawing::XShapes >& xLogicTarget
, AbstractShapeFactory* pShapeFactory )
- : LabelPositionHelper( pPosHelper, nDimensionCount, xLogicTarget, pShapeFactory )
+ : LabelPositionHelper( nDimensionCount, xLogicTarget, pShapeFactory )
, m_pPosHelper(pPosHelper)
{
}
More information about the Libreoffice-commits
mailing list