diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-06-19 16:03:21 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-06-20 07:51:22 +0200 |
commit | 19f3b88c1ee2ab546a92c28f155f4d65e0c464df (patch) | |
tree | f12119740ba1d7245b51e03364a490575a8f830a /chart2/source/model/template | |
parent | 6ee9f2c188290ba8a8bc6d435f645b31a05783ea (diff) |
loplugin:oncevar chart2
Change-Id: I2dd0939db440b5357225395e88680dd0b0fdbf43
Reviewed-on: https://gerrit.libreoffice.org/38970
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'chart2/source/model/template')
-rw-r--r-- | chart2/source/model/template/ChartTypeTemplate.cxx | 3 | ||||
-rw-r--r-- | chart2/source/model/template/PieChartTypeTemplate.cxx | 7 |
2 files changed, 4 insertions, 6 deletions
diff --git a/chart2/source/model/template/ChartTypeTemplate.cxx b/chart2/source/model/template/ChartTypeTemplate.cxx index 7e42baa89628..8e9e02dfa2c1 100644 --- a/chart2/source/model/template/ChartTypeTemplate.cxx +++ b/chart2/source/model/template/ChartTypeTemplate.cxx @@ -683,8 +683,7 @@ void ChartTypeTemplate::createAxes( //create missing axes if( rCoordSys.getLength() > 0 ) { - sal_Int32 nCooSysIdx = 0; - Reference< XCoordinateSystem > xCooSys( rCoordSys[nCooSysIdx] ); + Reference< XCoordinateSystem > xCooSys( rCoordSys[0] ); if(!xCooSys.is()) return; diff --git a/chart2/source/model/template/PieChartTypeTemplate.cxx b/chart2/source/model/template/PieChartTypeTemplate.cxx index 1c61f0004347..4cf0c415e207 100644 --- a/chart2/source/model/template/PieChartTypeTemplate.cxx +++ b/chart2/source/model/template/PieChartTypeTemplate.cxx @@ -326,8 +326,8 @@ sal_Bool SAL_CALL PieChartTypeTemplate::matchesTemplate( //check offset of outer series if( !aSeriesVec.empty() ) { - sal_Int32 nOuterSeriesIndex = 0; //@todo in future this will depend on Orientation of the radius axis scale - Reference< chart2::XDataSeries > xSeries( aSeriesVec[nOuterSeriesIndex] ); + //@todo in future this will depend on Orientation of the radius axis scale + Reference< chart2::XDataSeries > xSeries( aSeriesVec[0] ); Reference< beans::XPropertySet > xProp( xSeries, uno::UNO_QUERY_THROW ); xProp->getPropertyValue( "Offset") >>= fOffset; @@ -454,8 +454,7 @@ void SAL_CALL PieChartTypeTemplate::applyStyle( bool bTemplateUsesRings = false; getFastPropertyValue( PROP_PIE_TEMPLATE_USE_RINGS ) >>= bTemplateUsesRings; - sal_Int32 nOuterSeriesIndex = 0; //@todo in future this will depend on Orientation of the radius axis scale - if( nSeriesIndex == nOuterSeriesIndex ) + if( nSeriesIndex == 0 ) //@todo in future this will depend on Orientation of the radius axis scale { const OUString aOffsetPropName( "Offset" ); // get offset mode |