summaryrefslogtreecommitdiff
path: root/sc/source/ui
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2022-01-28 15:17:04 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2022-01-29 18:59:53 +0100
commitc3d5c9a08df77f9c0d0fd2493cf299dbad1a9dff (patch)
treef448517b6031741ab182685f3cf8ee332deac2f4 /sc/source/ui
parent58c849a94234f18eac020be66117aa2378487e2f (diff)
used TypedWhichId in the constructor of various svx *Item classes
to act as an extra check that we have the association of Item and TypedWhichId annotations correct. (*) requires that I add an upcasting constructor to TypedWhichId (*) Make the field dialog stuff in writer use a new item id FN_FIELD_DIALOG_DOC_PROPS instead of abusing the existing SID_DOCINFO Change-Id: Ica4aea930c80124609a063768c9af5a189df1c27 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129098 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui')
-rw-r--r--sc/source/ui/unoobj/afmtuno.cxx2
-rw-r--r--sc/source/ui/unoobj/cellsuno.cxx2
-rw-r--r--sc/source/ui/unoobj/styleuno.cxx2
-rw-r--r--sc/source/ui/view/tabvwsh5.cxx2
4 files changed, 4 insertions, 4 deletions
diff --git a/sc/source/ui/unoobj/afmtuno.cxx b/sc/source/ui/unoobj/afmtuno.cxx
index c3b52eafc4b7..15a8bcbafe1b 100644
--- a/sc/source/ui/unoobj/afmtuno.cxx
+++ b/sc/source/ui/unoobj/afmtuno.cxx
@@ -686,7 +686,7 @@ uno::Any SAL_CALL ScAutoFormatFieldObj::getPropertyValue( const OUString& aPrope
const ScRotateValueItem* pRotItem = pData->GetItem( nFieldIndex, ATTR_ROTATE_VALUE );
Degree100 nRot = pRotItem ? pRotItem->GetValue() : 0_deg100;
bool bStacked = static_cast<const ScVerticalStackCell*>(pItem)->GetValue();
- SvxOrientationItem( nRot, bStacked, 0 ).QueryValue( aVal );
+ SvxOrientationItem( nRot, bStacked, TypedWhichId<SvxOrientationItem>(0) ).QueryValue( aVal );
}
break;
default:
diff --git a/sc/source/ui/unoobj/cellsuno.cxx b/sc/source/ui/unoobj/cellsuno.cxx
index d8a5dc5fe43a..91483f02476e 100644
--- a/sc/source/ui/unoobj/cellsuno.cxx
+++ b/sc/source/ui/unoobj/cellsuno.cxx
@@ -2384,7 +2384,7 @@ void ScCellRangesBase::GetOnePropertyValue( const SfxItemPropertyMapEntry* pEntr
{
Degree100 nRot = pDataSet->Get(ATTR_ROTATE_VALUE).GetValue();
bool bStacked = static_cast<const ScVerticalStackCell&>(pDataSet->Get(pEntry->nWID)).GetValue();
- SvxOrientationItem( nRot, bStacked, 0 ).QueryValue( rAny );
+ SvxOrientationItem( nRot, bStacked, TypedWhichId<SvxOrientationItem>(0) ).QueryValue( rAny );
}
break;
default:
diff --git a/sc/source/ui/unoobj/styleuno.cxx b/sc/source/ui/unoobj/styleuno.cxx
index 4baa85a35476..b03f8dc0788b 100644
--- a/sc/source/ui/unoobj/styleuno.cxx
+++ b/sc/source/ui/unoobj/styleuno.cxx
@@ -1818,7 +1818,7 @@ uno::Any ScStyleObj::getPropertyValue_Impl( std::u16string_view aPropertyName )
{
Degree100 nRot = pItemSet->Get(ATTR_ROTATE_VALUE).GetValue();
bool bStacked = static_cast<const ScVerticalStackCell&>(pItemSet->Get(nWhich)).GetValue();
- SvxOrientationItem( nRot, bStacked, 0 ).QueryValue( aAny );
+ SvxOrientationItem( nRot, bStacked, TypedWhichId<SvxOrientationItem>(0) ).QueryValue( aAny );
}
break;
case ATTR_PAGE_SCALE:
diff --git a/sc/source/ui/view/tabvwsh5.cxx b/sc/source/ui/view/tabvwsh5.cxx
index 62949eaaa472..0758a9fe3724 100644
--- a/sc/source/ui/view/tabvwsh5.cxx
+++ b/sc/source/ui/view/tabvwsh5.cxx
@@ -378,7 +378,7 @@ std::unique_ptr<SvxNumberInfoItem> ScTabViewShell::MakeNumberInfoItem( ScDocumen
}
return std::make_unique<SvxNumberInfoItem>(
- rDoc.GetFormatTable(), static_cast<sal_uInt16>(SID_ATTR_NUMBERFORMAT_INFO));
+ rDoc.GetFormatTable(), SID_ATTR_NUMBERFORMAT_INFO);
}
void ScTabViewShell::UpdateNumberFormatter(