diff options
author | Noel Grandin <noel@peralex.com> | 2016-01-15 10:42:04 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2016-01-15 10:42:24 +0200 |
commit | f0920199f2983a89b66e3b64d555353d7fe47e52 (patch) | |
tree | ad2f0dd43adfa706a204bfccfb60699259e5c37d | |
parent | 51b71a7be13611acc02a702cf025425fc746f4a2 (diff) |
-Werror=unused-but-set-variable
Change-Id: I981e1b660dc94333935b3a451847198940e47e99
-rw-r--r-- | xmloff/source/style/GradientStyle.cxx | 23 | ||||
-rw-r--r-- | xmloff/source/style/HatchStyle.cxx | 15 |
2 files changed, 7 insertions, 31 deletions
diff --git a/xmloff/source/style/GradientStyle.cxx b/xmloff/source/style/GradientStyle.cxx index 3c33b463f83b..141fcc901a3c 100644 --- a/xmloff/source/style/GradientStyle.cxx +++ b/xmloff/source/style/GradientStyle.cxx @@ -98,9 +98,6 @@ void XMLGradientStyleImport::importXML( XML_TOKEN_MAP_END }; - bool bHasName = false; - bool bHasStyle = false; - bool bHasStartColor = false; OUString aDisplayName; awt::Gradient aGradient; @@ -127,15 +124,10 @@ void XMLGradientStyleImport::importXML( switch( aTokenMap.Get( nPrefix, aStrAttrName ) ) { case XML_TOK_GRADIENT_NAME: - { - rStrName = rStrValue; - bHasName = true; - } + rStrName = rStrValue; break; case XML_TOK_GRADIENT_DISPLAY_NAME: - { - aDisplayName = rStrValue; - } + aDisplayName = rStrValue; break; case XML_TOK_GRADIENT_STYLE: { @@ -143,7 +135,6 @@ void XMLGradientStyleImport::importXML( if( SvXMLUnitConverter::convertEnum( eValue, rStrValue, pXML_GradientStyle_Enum ) ) { aGradient.Style = (awt::GradientStyle) eValue; - bHasStyle = true; } } break; @@ -156,16 +147,10 @@ void XMLGradientStyleImport::importXML( aGradient.YOffset = static_cast< sal_Int16 >( nTmpValue ); break; case XML_TOK_GRADIENT_STARTCOLOR: - { - bHasStartColor = ::sax::Converter::convertColor( - aGradient.StartColor, rStrValue); - } + ::sax::Converter::convertColor(aGradient.StartColor, rStrValue); break; case XML_TOK_GRADIENT_ENDCOLOR: - { - bHasStartColor = ::sax::Converter::convertColor( - aGradient.EndColor, rStrValue); - } + ::sax::Converter::convertColor(aGradient.EndColor, rStrValue); break; case XML_TOK_GRADIENT_STARTINT: ::sax::Converter::convertPercent( nTmpValue, rStrValue ); diff --git a/xmloff/source/style/HatchStyle.cxx b/xmloff/source/style/HatchStyle.cxx index 9b76e19fe25f..43c1e029e953 100644 --- a/xmloff/source/style/HatchStyle.cxx +++ b/xmloff/source/style/HatchStyle.cxx @@ -84,10 +84,7 @@ void XMLHatchStyleImport::importXML( XML_TOKEN_MAP_END }; - bool bHasName = false; bool bHasStyle = false; - bool bHasColor = false; - bool bHasDist = false; OUString aDisplayName; drawing::Hatch aHatch; @@ -111,10 +108,7 @@ void XMLHatchStyleImport::importXML( switch( aTokenMap.Get( nPrefix, aStrAttrName ) ) { case XML_TOK_HATCH_NAME: - { - rStrName = rStrValue; - bHasName = true; - } + rStrName = rStrValue; break; case XML_TOK_HATCH_DISPLAY_NAME: aDisplayName = rStrValue; @@ -128,13 +122,10 @@ void XMLHatchStyleImport::importXML( } break; case XML_TOK_HATCH_COLOR: - { - bHasColor = ::sax::Converter::convertColor( - aHatch.Color, rStrValue); - } + ::sax::Converter::convertColor(aHatch.Color, rStrValue); break; case XML_TOK_HATCH_DISTANCE: - bHasDist = rUnitConverter.convertMeasureToCore( + rUnitConverter.convertMeasureToCore( (sal_Int32&)aHatch.Distance, rStrValue ); break; case XML_TOK_HATCH_ROTATION: |