summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-08-11 11:51:09 +0100
committerCaolán McNamara <caolanm@redhat.com>2017-08-11 11:52:49 +0100
commita162b21c2b393534a9f6433c9b2b674aaaecf1a7 (patch)
tree5a1fb22ab79b76d953d3e2959c479580f850cfd0 /cui
parent884be65e0edafe5f3433ef8ff0e6d30ced7c1a46 (diff)
improve scoping a little
Change-Id: Ie2e86852f7c4754070d3eb7e8981d674f04a6d80
Diffstat (limited to 'cui')
-rw-r--r--cui/source/tabpages/backgrnd.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/cui/source/tabpages/backgrnd.cxx b/cui/source/tabpages/backgrnd.cxx
index 87aa1afad9f1..b3684632209e 100644
--- a/cui/source/tabpages/backgrnd.cxx
+++ b/cui/source/tabpages/backgrnd.cxx
@@ -594,11 +594,11 @@ bool SvxBackgroundTabPage::FillItemSet( SfxItemSet* rCoreSet )
sal_uInt16 nWhich = GetWhich( nSlot );
const SfxPoolItem* pOld = GetOldItem( *rCoreSet, nSlot );
- SfxItemState eOldItemState = rCoreSet->GetItemState(nSlot, false);
- const SfxItemSet& rOldSet = GetItemSet();
-
- if ( pOld )
+ if (pOld)
{
+ SfxItemState eOldItemState = rCoreSet->GetItemState(nSlot, false);
+ const SfxItemSet& rOldSet = GetItemSet();
+
const SvxBrushItem& rOldItem = static_cast<const SvxBrushItem&>(*pOld);
SvxGraphicPosition eOldPos = rOldItem.GetGraphicPos();
const bool bIsBrush = ( drawing::FillStyle_SOLID == lcl_getFillStyle(m_pLbSelect) );