summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-04-29 21:20:43 +0100
committerCaolán McNamara <caolanm@redhat.com>2015-04-29 21:20:43 +0100
commit3a6866c2953c17a55536fa434b9fceda670d0685 (patch)
tree3f84c201f4a59d648b08dfc76059e468f279321c
parentaa121a212320e46dc8f835766050c10998dcd197 (diff)
coverity#1296209 Logically dead code (gold)
Change-Id: I68be0901ab0ee37caaa9338b6c499d0086c2c968
-rw-r--r--sw/source/core/unocore/swunohelper.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/sw/source/core/unocore/swunohelper.cxx b/sw/source/core/unocore/swunohelper.cxx
index ceb061b35d59..05dd0da1f1f8 100644
--- a/sw/source/core/unocore/swunohelper.cxx
+++ b/sw/source/core/unocore/swunohelper.cxx
@@ -282,7 +282,8 @@ bool needToMapFillItemsToSvxBrushItemTypes(const SfxItemSet& rSet,
// here different FillStyles can be excluded for export; it will depend on the
// quality these fallbacks can reach. That again is done in getSvxBrushItemFromSourceSet,
// take a look there how the superset of DrawObject FillStyles is mapped to SvxBrushItem.
- switch (pXFillStyleItem->GetValue())
+ const drawing::FillStyle eFill = pXFillStyleItem->GetValue();
+ switch (eFill)
{
case drawing::FillStyle_NONE:
return false; // ignoring some extremely limited XFillColorItem eval
@@ -294,13 +295,13 @@ bool needToMapFillItemsToSvxBrushItemTypes(const SfxItemSet& rSet,
{
case MID_BACK_COLOR:
// Gradient/Hatch always have emulated color
- return (drawing::FillStyle_SOLID != nMID)
+ return (drawing::FillStyle_SOLID != eFill)
|| SfxItemState::SET == rSet.GetItemState(XATTR_FILLCOLOR)
|| SfxItemState::SET == rSet.GetItemState(XATTR_FILLTRANSPARENCE)
|| SfxItemState::SET == rSet.GetItemState(XATTR_FILLFLOATTRANSPARENCE);
case MID_BACK_COLOR_R_G_B:
// Gradient/Hatch always have emulated color
- return (drawing::FillStyle_SOLID != nMID)
+ return (drawing::FillStyle_SOLID != eFill)
|| SfxItemState::SET == rSet.GetItemState(XATTR_FILLCOLOR);
case MID_BACK_COLOR_TRANSPARENCY:
return SfxItemState::SET == rSet.GetItemState(XATTR_FILLTRANSPARENCE)