Kaydet (Commit) c79b7fd8 authored tarafından Noel Grandin's avatar Noel Grandin

loplugin:unusedfields in chart2

Change-Id: I7da22cc193d9fadf9a3b5dc1453f5574d2357c31
üst ad278c2b
...@@ -977,7 +977,7 @@ void AreaChart::createShapes() ...@@ -977,7 +977,7 @@ void AreaChart::createShapes()
{ {
if(LABEL_ALIGN_CENTER==eAlignment || m_nDimension == 3 ) if(LABEL_ALIGN_CENTER==eAlignment || m_nDimension == 3 )
nOffset = 0; 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 ) ); .transformSceneToScreenPosition( aScenePosition3D ) );
} }
......
...@@ -263,7 +263,7 @@ awt::Point BarChart::getLabelScreenPositionAndAlignment( ...@@ -263,7 +263,7 @@ awt::Point BarChart::getLabelScreenPositionAndAlignment(
drawing::Position3D aScenePosition3D( pPosHelper-> drawing::Position3D aScenePosition3D( pPosHelper->
transformScaledLogicToScene( fX, fY, fZ, true ) ); transformScaledLogicToScene( fX, fY, fZ, true ) );
return LabelPositionHelper(pPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory) return LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory)
.transformSceneToScreenPosition( aScenePosition3D ); .transformSceneToScreenPosition( aScenePosition3D );
} }
......
...@@ -109,8 +109,8 @@ void BubbleChart::calculateBubbleSizeScalingFactor() ...@@ -109,8 +109,8 @@ void BubbleChart::calculateBubbleSizeScalingFactor()
drawing::Position3D aSceneMinPos( m_pMainPosHelper->transformLogicToScene( m_pMainPosHelper->getLogicMinX(),m_pMainPosHelper->getLogicMinY(),fLogicZ, false ) ); 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 ) ); 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 aScreenMinPos( LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory).transformSceneToScreenPosition( aSceneMinPos ) );
awt::Point aScreenMaxPos( LabelPositionHelper(m_pMainPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory).transformSceneToScreenPosition( aSceneMaxPos ) ); awt::Point aScreenMaxPos( LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory).transformSceneToScreenPosition( aSceneMaxPos ) );
sal_Int32 nWidth = abs( aScreenMaxPos.X - aScreenMinPos.X ); sal_Int32 nWidth = abs( aScreenMaxPos.X - aScreenMinPos.X );
sal_Int32 nHeight = abs( aScreenMaxPos.Y - aScreenMinPos.Y ); sal_Int32 nHeight = abs( aScreenMaxPos.Y - aScreenMinPos.Y );
...@@ -380,7 +380,7 @@ void BubbleChart::createShapes() ...@@ -380,7 +380,7 @@ void BubbleChart::createShapes()
break; break;
} }
awt::Point aScreenPosition2D( LabelPositionHelper(pPosHelper,m_nDimension,m_xLogicTarget,m_pShapeFactory) awt::Point aScreenPosition2D( LabelPositionHelper(m_nDimension,m_xLogicTarget,m_pShapeFactory)
.transformSceneToScreenPosition( aScenePosition3D ) ); .transformSceneToScreenPosition( aScenePosition3D ) );
sal_Int32 nOffset = 0; sal_Int32 nOffset = 0;
if(LABEL_ALIGN_CENTER!=eAlignment) if(LABEL_ALIGN_CENTER!=eAlignment)
......
...@@ -575,12 +575,9 @@ GL3DBarChart::GL3DBarChart( ...@@ -575,12 +575,9 @@ GL3DBarChart::GL3DBarChart(
mpWindow->getContext().resetCurrent(); mpWindow->getContext().resetCurrent();
} }
GL3DBarChart::BarInformation::BarInformation(const glm::vec3& rPos, float nVal, GL3DBarChart::BarInformation::BarInformation(const glm::vec3& rPos, float nVal):
sal_Int32 nIndex, sal_Int32 nSeriesIndex):
maPos(rPos), maPos(rPos),
mnVal(nVal), mnVal(nVal)
mnIndex(nIndex),
mnSeriesIndex(nSeriesIndex)
{ {
} }
...@@ -711,7 +708,7 @@ void GL3DBarChart::create3DShapes(const std::vector<std::unique_ptr<VDataSeries> ...@@ -711,7 +708,7 @@ void GL3DBarChart::create3DShapes(const std::vector<std::unique_ptr<VDataSeries>
maBarMap.insert(std::pair<sal_uInt32, BarInformation>(nId, maBarMap.insert(std::pair<sal_uInt32, BarInformation>(nId,
BarInformation(glm::vec3(nXPos, nYPos, float(nVal/nMaxVal)), BarInformation(glm::vec3(nXPos, nYPos, float(nVal/nMaxVal)),
nVal, nIndex, nSeriesIndex))); nVal)));
recordBarHistory(nId, nVal); recordBarHistory(nId, nVal);
if (mbBenchMarkMode) if (mbBenchMarkMode)
{ {
......
...@@ -671,7 +671,7 @@ void NetChart::createShapes() ...@@ -671,7 +671,7 @@ void NetChart::createShapes()
{ {
if(LABEL_ALIGN_CENTER==eAlignment ) if(LABEL_ALIGN_CENTER==eAlignment )
nOffset = 0; 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 ) ); .transformSceneToScreenPosition( aScenePosition3D ) );
} }
......
...@@ -151,11 +151,8 @@ private: ...@@ -151,11 +151,8 @@ private:
{ {
glm::vec3 maPos; glm::vec3 maPos;
float mnVal; float mnVal;
sal_Int32 mnIndex;
sal_Int32 mnSeriesIndex;
BarInformation(const glm::vec3& rPos, float nVal, BarInformation(const glm::vec3& rPos, float nVal);
sal_Int32 nIndex, sal_Int32 nSeriesIndex);
}; };
std::map<sal_uInt32, const BarInformation> maBarMap; std::map<sal_uInt32, const BarInformation> maBarMap;
......
...@@ -59,9 +59,6 @@ struct LightSource ...@@ -59,9 +59,6 @@ struct LightSource
glm::vec4 lightColor; glm::vec4 lightColor;
glm::vec4 positionWorldspace; glm::vec4 positionWorldspace;
float lightPower; float lightPower;
float pad1;
float pad2;
float pad3;
}; };
struct GlobalLights struct GlobalLights
......
...@@ -38,8 +38,7 @@ class LabelPositionHelper ...@@ -38,8 +38,7 @@ class LabelPositionHelper
{ {
public: public:
LabelPositionHelper( LabelPositionHelper(
PlottingPositionHelper* pPosHelper sal_Int32 nDimensionCount
, sal_Int32 nDimensionCount
, const ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShapes >& xLogicTarget , const ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShapes >& xLogicTarget
, AbstractShapeFactory* pShapeFactory ); , AbstractShapeFactory* pShapeFactory );
virtual ~LabelPositionHelper(); virtual ~LabelPositionHelper();
...@@ -59,7 +58,6 @@ private: ...@@ -59,7 +58,6 @@ private:
LabelPositionHelper(); LabelPositionHelper();
protected: protected:
PlottingPositionHelper* m_pPosHelper;
sal_Int32 m_nDimensionCount; sal_Int32 m_nDimensionCount;
private: private:
......
...@@ -33,12 +33,10 @@ using namespace ::com::sun::star; ...@@ -33,12 +33,10 @@ using namespace ::com::sun::star;
using namespace ::com::sun::star::chart2; using namespace ::com::sun::star::chart2;
LabelPositionHelper::LabelPositionHelper( LabelPositionHelper::LabelPositionHelper(
PlottingPositionHelper* pPosHelper sal_Int32 nDimensionCount
, sal_Int32 nDimensionCount
, const uno::Reference< drawing::XShapes >& xLogicTarget , const uno::Reference< drawing::XShapes >& xLogicTarget
, AbstractShapeFactory* pShapeFactory ) , AbstractShapeFactory* pShapeFactory )
: m_pPosHelper(pPosHelper) : m_nDimensionCount(nDimensionCount)
, m_nDimensionCount(nDimensionCount)
, m_xLogicTarget(xLogicTarget) , m_xLogicTarget(xLogicTarget)
, m_pShapeFactory(pShapeFactory) , m_pShapeFactory(pShapeFactory)
{ {
......
...@@ -187,8 +187,6 @@ private: ...@@ -187,8 +187,6 @@ private:
float m_BackgroundColor[16]; float m_BackgroundColor[16];
std::list <PointList> m_PieSegment2DShapePointList; std::list <PointList> m_PieSegment2DShapePointList;
PointList m_Symbol2DPointList;
std::list<PointList> m_Symbol2DShapePointList;
GLuint m_SymbolProID; GLuint m_SymbolProID;
GLuint m_SymbolVertexID; GLuint m_SymbolVertexID;
......
...@@ -35,7 +35,7 @@ PolarLabelPositionHelper::PolarLabelPositionHelper( ...@@ -35,7 +35,7 @@ PolarLabelPositionHelper::PolarLabelPositionHelper(
, sal_Int32 nDimensionCount , sal_Int32 nDimensionCount
, const uno::Reference< drawing::XShapes >& xLogicTarget , const uno::Reference< drawing::XShapes >& xLogicTarget
, AbstractShapeFactory* pShapeFactory ) , AbstractShapeFactory* pShapeFactory )
: LabelPositionHelper( pPosHelper, nDimensionCount, xLogicTarget, pShapeFactory ) : LabelPositionHelper( nDimensionCount, xLogicTarget, pShapeFactory )
, m_pPosHelper(pPosHelper) , m_pPosHelper(pPosHelper)
{ {
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment