summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2022-02-15 11:56:52 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2022-02-15 14:32:53 +0100
commitbdb66b740681e9d3a94fbd0226ae1a4f1663e589 (patch)
treec5667f54da69bf0b03d7757d8cb24f1359169882 /sw
parent6125517102493341b8172acd463dd9126afa7a64 (diff)
fix SfxItemPool::GetWhich change
In commit 339fde9d905135e24b2f4e204009ee289d678b0c Author: Noel Grandin <noel.grandin@collabora.co.uk> Date: Tue Feb 15 08:56:13 2022 +0200 add typed GetWhich operations I got the parameter type wrong Change-Id: I7b1d86bc06da7feb3238f5033bbffbd166cd4fdd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129959 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r--sw/source/ui/misc/pgfnote.cxx6
-rw-r--r--sw/source/ui/misc/pggrid.cxx4
-rw-r--r--sw/source/uibase/frmdlg/colex.cxx6
3 files changed, 8 insertions, 8 deletions
diff --git a/sw/source/ui/misc/pgfnote.cxx b/sw/source/ui/misc/pgfnote.cxx
index 741cd51802d4..452aab1874d1 100644
--- a/sw/source/ui/misc/pgfnote.cxx
+++ b/sw/source/ui/misc/pgfnote.cxx
@@ -267,12 +267,12 @@ void SwFootNotePage::ActivatePage(const SfxItemSet& rSet)
{
const SfxItemSet& rHeaderSet = static_cast<const SvxSetItem*>(pItem)->GetItemSet();
const SfxBoolItem& rHeaderOn =
- static_cast<const SfxBoolItem&>(rHeaderSet.Get( rSet.GetPool()->GetWhich( SID_ATTR_PAGE_ON ) ));
+ rHeaderSet.Get( rSet.GetPool()->GetWhich( SID_ATTR_PAGE_ON ) );
if ( rHeaderOn.GetValue() )
{
const SvxSizeItem& rSizeItem =
- static_cast<const SvxSizeItem&>(rHeaderSet.Get(rSet.GetPool()->GetWhich(SID_ATTR_PAGE_SIZE)));
+ rHeaderSet.Get(rSet.GetPool()->GetWhich(SID_ATTR_PAGE_SIZE));
lMaxHeight -= rSizeItem.GetSize().Height();
}
}
@@ -286,7 +286,7 @@ void SwFootNotePage::ActivatePage(const SfxItemSet& rSet)
if ( rFooterOn.GetValue() )
{
const SvxSizeItem& rSizeItem =
- static_cast<const SvxSizeItem&>(rFooterSet.Get( rSet.GetPool()->GetWhich( SID_ATTR_PAGE_SIZE ) ));
+ rFooterSet.Get( rSet.GetPool()->GetWhich( SID_ATTR_PAGE_SIZE ) );
lMaxHeight -= rSizeItem.GetSize().Height();
}
}
diff --git a/sw/source/ui/misc/pggrid.cxx b/sw/source/ui/misc/pggrid.cxx
index 875bee7ad331..c06f5e91c2fe 100644
--- a/sw/source/ui/misc/pggrid.cxx
+++ b/sw/source/ui/misc/pggrid.cxx
@@ -282,12 +282,12 @@ void SwTextGridPage::UpdatePageSize(const SfxItemSet& rSet)
{
const SfxItemSet& rExtraSet = static_cast<const SvxSetItem*>(pItem)->GetItemSet();
const SfxBoolItem& rOn =
- static_cast<const SfxBoolItem&>(rExtraSet.Get( rSet.GetPool()->GetWhich( SID_ATTR_PAGE_ON ) ));
+ rExtraSet.Get( rSet.GetPool()->GetWhich( SID_ATTR_PAGE_ON ) );
if ( rOn.GetValue() )
{
const SvxSizeItem& rSizeItem =
- static_cast<const SvxSizeItem&>(rExtraSet.Get(rSet.GetPool()->GetWhich(SID_ATTR_PAGE_SIZE)));
+ rExtraSet.Get(rSet.GetPool()->GetWhich(SID_ATTR_PAGE_SIZE));
nDistanceUL += rSizeItem.GetSize().Height();
}
}
diff --git a/sw/source/uibase/frmdlg/colex.cxx b/sw/source/uibase/frmdlg/colex.cxx
index d1fb2bd9c952..0b11ab168ab4 100644
--- a/sw/source/uibase/frmdlg/colex.cxx
+++ b/sw/source/uibase/frmdlg/colex.cxx
@@ -99,12 +99,12 @@ void SwPageExample::UpdateExample( const SfxItemSet& rSet )
{
const SfxItemSet& rHeaderSet = static_cast<const SvxSetItem*>(pItem)->GetItemSet();
const SfxBoolItem& rHeaderOn =
- static_cast<const SfxBoolItem&>(rHeaderSet.Get( pPool->GetWhich( SID_ATTR_PAGE_ON ) ) );
+ rHeaderSet.Get( pPool->GetWhich( SID_ATTR_PAGE_ON ) );
if ( rHeaderOn.GetValue() )
{
const SvxSizeItem& rSize =
- static_cast<const SvxSizeItem&>(rHeaderSet.Get(pPool->GetWhich(SID_ATTR_PAGE_SIZE)));
+ rHeaderSet.Get(pPool->GetWhich(SID_ATTR_PAGE_SIZE));
const SvxULSpaceItem& rUL = static_cast<const SvxULSpaceItem&>(rHeaderSet.Get(
pPool->GetWhich(SID_ATTR_ULSPACE)));
@@ -142,7 +142,7 @@ void SwPageExample::UpdateExample( const SfxItemSet& rSet )
if ( rFooterOn.GetValue() )
{
const SvxSizeItem& rSize =
- static_cast<const SvxSizeItem&>(rFooterSet.Get( pPool->GetWhich( SID_ATTR_PAGE_SIZE ) ));
+ rFooterSet.Get( pPool->GetWhich( SID_ATTR_PAGE_SIZE ) );
const SvxULSpaceItem& rUL = static_cast<const SvxULSpaceItem&>(rFooterSet.Get(
pPool->GetWhich( SID_ATTR_ULSPACE ) ));