summaryrefslogtreecommitdiff
path: root/chart2
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-11-06 10:16:38 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-11-06 10:28:47 +0100
commit819149fb1f71fc13ffdc288736ce65bb3c6c75d8 (patch)
tree55e663505dce8b7a36ec5aab1f8d6cc956522cf5 /chart2
parent00055d49f35bbabd46d00fefd395b46872ed45aa (diff)
loplugin:collapseif in accessibility..cui
Change-Id: I1437b493f3289b4ac97d061bd71973580571e792 Reviewed-on: https://gerrit.libreoffice.org/62933 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'chart2')
-rw-r--r--chart2/source/controller/dialogs/dlg_View3D.cxx7
-rw-r--r--chart2/source/model/template/StockChartTypeTemplate.cxx7
2 files changed, 4 insertions, 10 deletions
diff --git a/chart2/source/controller/dialogs/dlg_View3D.cxx b/chart2/source/controller/dialogs/dlg_View3D.cxx
index 8c7e97122f08..e4db6f6a2818 100644
--- a/chart2/source/controller/dialogs/dlg_View3D.cxx
+++ b/chart2/source/controller/dialogs/dlg_View3D.cxx
@@ -80,11 +80,8 @@ void View3DDialog::dispose()
short View3DDialog::Execute()
{
short nResult = TabDialog::Execute();
- if( nResult == RET_OK )
- {
- if( m_pGeometry )
- m_pGeometry->commitPendingChanges();
- }
+ if( nResult == RET_OK && m_pGeometry )
+ m_pGeometry->commitPendingChanges();
return nResult;
}
diff --git a/chart2/source/model/template/StockChartTypeTemplate.cxx b/chart2/source/model/template/StockChartTypeTemplate.cxx
index 3a592071169f..1e452770fb4c 100644
--- a/chart2/source/model/template/StockChartTypeTemplate.cxx
+++ b/chart2/source/model/template/StockChartTypeTemplate.cxx
@@ -219,11 +219,8 @@ void SAL_CALL StockChartTypeTemplate::applyStyle(
bool bHasVolume = false;
getFastPropertyValue( PROP_STOCKCHARTTYPE_TEMPLATE_VOLUME ) >>= bHasVolume;
- if( bHasVolume )
- {
- if( nChartTypeIndex != 0 )
- nNewAxisIndex = 1;
- }
+ if( bHasVolume && nChartTypeIndex != 0 )
+ nNewAxisIndex = 1;
Reference< beans::XPropertySet > xProp( xSeries, uno::UNO_QUERY );
if( xProp.is() )