summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2014-04-22 12:22:11 +0200
committerMichael Stahl <mstahl@redhat.com>2014-04-22 12:40:29 +0200
commitd286ffc3adb5386651e177cbc23512436d89d35f (patch)
tree35ad87df113a547a0bb6fc41636643fe6758acd9
parent0fbc3a87f78663d9ace98221024f581d5e0c86d9 (diff)
fix the getProperty case more thoroughly (related: fdo#77340)
Change-Id: I0cb042474c58b38a3e9a9073a262041b0ef185c7
-rw-r--r--sw/source/core/unocore/unostyle.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/sw/source/core/unocore/unostyle.cxx b/sw/source/core/unocore/unostyle.cxx
index d5ac4302367b..e36810852a1c 100644
--- a/sw/source/core/unocore/unostyle.cxx
+++ b/sw/source/core/unocore/unostyle.cxx
@@ -1931,7 +1931,7 @@ static void lcl_SetStyleProperty(const SfxItemPropertySimpleEntry& rEntry,
{
if (MID_PAGEDESC_PAGEDESCNAME != nMemberId)
break;
- // Sonderbehandlung RES_PAGEDESC
+ // special handling for RES_PAGEDESC
if(aValue.getValueType() != ::getCppuType((const OUString*)0))
throw lang::IllegalArgumentException();
SfxItemSet& rStyleSet = rBase.GetItemSet();
@@ -2387,10 +2387,11 @@ static uno::Any lcl_GetStyleProperty(const SfxItemPropertySimpleEntry& rEntry,
}
case RES_PAGEDESC :
{
- // Sonderbehandlung RES_PAGEDESC
+ if (MID_PAGEDESC_PAGEDESCNAME != nMemberId)
+ break;
+ // special handling for RES_PAGEDESC
const SfxPoolItem* pItem;
- if (MID_PAGEDESC_PAGEDESCNAME == nMemberId &&
- SFX_ITEM_SET == rBase.GetItemSet().GetItemState(RES_PAGEDESC, true, &pItem))
+ if (SFX_ITEM_SET == rBase.GetItemSet().GetItemState(RES_PAGEDESC, true, &pItem))
{
const SwPageDesc* pDesc = ((const SwFmtPageDesc*)pItem)->GetPageDesc();
if(pDesc)
@@ -2400,9 +2401,8 @@ static uno::Any lcl_GetStyleProperty(const SfxItemPropertySimpleEntry& rEntry,
aRet <<= aString;
}
- bDone = true;
}
-
+ bDone = true;
break;
}
case FN_UNO_IS_AUTO_UPDATE: