From 5404f75a2fa863b97bdf8432f647053f0bff726e Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 7 Nov 2018 09:26:57 +0200 Subject: loplugin:collapseif in sdext..svx Change-Id: I188d9e9b53e00acfbae3c7acd54de28f084c4b3f Reviewed-on: https://gerrit.libreoffice.org/62985 Tested-by: Jenkins Reviewed-by: Noel Grandin --- svx/source/tbxctrls/extrusioncontrols.cxx | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'svx/source/tbxctrls') diff --git a/svx/source/tbxctrls/extrusioncontrols.cxx b/svx/source/tbxctrls/extrusioncontrols.cxx index 438aa466b89c..70b170010478 100644 --- a/svx/source/tbxctrls/extrusioncontrols.cxx +++ b/svx/source/tbxctrls/extrusioncontrols.cxx @@ -746,18 +746,15 @@ void ExtrusionLightingWindow::SelectHdl(void const * pControl) if( pControl == this ) { int nLevel = getSelectedEntryId(); - if( nLevel >= 0 ) + if( nLevel >= 0 && nLevel != 3 ) { - if( nLevel != 3 ) - { - Sequence< PropertyValue > aArgs( 1 ); - aArgs[0].Name = OUString(g_sExtrusionLightingIntensity).copy(5); - aArgs[0].Value <<= static_cast(nLevel); + Sequence< PropertyValue > aArgs( 1 ); + aArgs[0].Name = OUString(g_sExtrusionLightingIntensity).copy(5); + aArgs[0].Value <<= static_cast(nLevel); - mrController.dispatchCommand( g_sExtrusionLightingIntensity, aArgs ); + mrController.dispatchCommand( g_sExtrusionLightingIntensity, aArgs ); - implSetIntensity( nLevel, true ); - } + implSetIntensity( nLevel, true ); } } else -- cgit