diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2023-05-26 11:18:17 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2023-05-26 13:49:54 +0200 |
commit | 5315e6069e425aad88873beb5344bb8ea31e0c55 (patch) | |
tree | ee8928e3fb00e52a04faa1cc5a3424b3ed0f8ff2 /include | |
parent | a82e7cc9ed17a2500ad8cb9ffe54c412b0d8063f (diff) |
use more TypedWhichId
which flushed out an inconsistency in how SID_NUMBER_TYPE_FORMAT was being used
Change-Id: Ib59ae4c4950136703d18d7485db432a39e3dc39c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152300
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include')
-rw-r--r-- | include/editeng/charrotateitem.hxx | 4 | ||||
-rw-r--r-- | include/editeng/charscaleitem.hxx | 2 | ||||
-rw-r--r-- | include/editeng/editids.hrc | 4 | ||||
-rw-r--r-- | include/editeng/emphasismarkitem.hxx | 2 | ||||
-rw-r--r-- | include/editeng/paravertalignitem.hxx | 3 | ||||
-rw-r--r-- | include/editeng/writingmodeitem.hxx | 2 | ||||
-rw-r--r-- | include/sfx2/sfxsids.hrc | 8 | ||||
-rw-r--r-- | include/sfx2/zoomitem.hxx | 2 | ||||
-rw-r--r-- | include/svx/svxids.hrc | 33 |
9 files changed, 30 insertions, 30 deletions
diff --git a/include/editeng/charrotateitem.hxx b/include/editeng/charrotateitem.hxx index 49fb3f345bb3..d8a773065575 100644 --- a/include/editeng/charrotateitem.hxx +++ b/include/editeng/charrotateitem.hxx @@ -35,7 +35,7 @@ class EDITENG_DLLPUBLIC SvxTextRotateItem : public SfxUInt16Item { public: - SvxTextRotateItem(Degree10 nValue, const sal_uInt16 nId); + SvxTextRotateItem(Degree10 nValue, TypedWhichId<SvxTextRotateItem> nId); virtual SvxTextRotateItem* Clone(SfxItemPool *pPool = nullptr) const override; @@ -81,7 +81,7 @@ public: SvxCharRotateItem( Degree10 nValue /*= 0*/, bool bFitIntoLine /*= false*/, - const sal_uInt16 nId ); + TypedWhichId<SvxCharRotateItem> nId ); virtual SvxCharRotateItem* Clone( SfxItemPool *pPool = nullptr ) const override; diff --git a/include/editeng/charscaleitem.hxx b/include/editeng/charscaleitem.hxx index fff4fa8efae9..7e5025fb37f7 100644 --- a/include/editeng/charscaleitem.hxx +++ b/include/editeng/charscaleitem.hxx @@ -38,7 +38,7 @@ public: static SfxPoolItem* CreateDefault(); SvxCharScaleWidthItem( sal_uInt16 nValue /*= 100*/, - const sal_uInt16 nId ); + TypedWhichId<SvxCharScaleWidthItem> nId ); virtual SvxCharScaleWidthItem* Clone( SfxItemPool *pPool = nullptr ) const override; diff --git a/include/editeng/editids.hrc b/include/editeng/editids.hrc index f33972743aa0..9ff4884fbcbc 100644 --- a/include/editeng/editids.hrc +++ b/include/editeng/editids.hrc @@ -128,7 +128,7 @@ class SvxWordLineModeItem; #define SID_ATTR_PARA_OUTLLEVEL TypedWhichId<SfxInt16Item>( SID_SVX_START + 300 ) #define SID_FIELD ( SID_SVX_START + 363 ) // related to EE_FEATURE_FIELD #define SID_ATTR_PARA_REGISTER ( SID_SVX_START + 413 ) -#define SID_ATTR_PARA_PAGENUM ( SID_SVX_START + 457 ) +#define SID_ATTR_PARA_PAGENUM TypedWhichId<SfxUInt16Item>( SID_SVX_START + 457 ) #define SID_ATTR_PARA_NUMRULE ( SID_SVX_START + 587 ) #define SID_ATTR_BRUSH_CHAR TypedWhichId<SvxBrushItem>( SID_SVX_START + 591 ) #define SID_ATTR_NUMBERING_RULE TypedWhichId<SvxNumBulletItem>( SID_SVX_START + 855 ) @@ -152,7 +152,7 @@ class SvxWordLineModeItem; #define SID_ATTR_CHAR_VERTICAL ( SID_SVX_START + 905 ) #define SID_ATTR_CHAR_ROTATED TypedWhichId<SvxCharRotateItem>( SID_SVX_START + 910 ) #define SID_ATTR_CHAR_SCALEWIDTH TypedWhichId<SvxCharScaleWidthItem>( SID_SVX_START + 911 ) -#define SID_ATTR_CHAR_WIDTH_FIT_TO_LINE ( SID_SVX_START + 919 ) +#define SID_ATTR_CHAR_WIDTH_FIT_TO_LINE TypedWhichId<SfxUInt16Item>( SID_SVX_START + 919 ) #define SID_ATTR_CHAR_RELIEF TypedWhichId<SvxCharReliefItem>( SID_SVX_START + 920 ) #define SID_PARA_VERTALIGN TypedWhichId<SvxParaVertAlignItem>( SID_SVX_START + 925 ) #define SID_ATTR_FRAMEDIRECTION TypedWhichId<SvxFrameDirectionItem>( SID_SVX_START + 944 ) diff --git a/include/editeng/emphasismarkitem.hxx b/include/editeng/emphasismarkitem.hxx index f54c857353c9..e0fd74cf4400 100644 --- a/include/editeng/emphasismarkitem.hxx +++ b/include/editeng/emphasismarkitem.hxx @@ -36,7 +36,7 @@ public: static SfxPoolItem* CreateDefault(); SvxEmphasisMarkItem( const FontEmphasisMark eVal /*= FontEmphasisMark::NONE*/, - const sal_uInt16 nId ); + TypedWhichId<SvxEmphasisMarkItem> nId ); // "pure virtual Methods" from SfxPoolItem + SfxEnumItem virtual bool GetPresentation( SfxItemPresentation ePres, diff --git a/include/editeng/paravertalignitem.hxx b/include/editeng/paravertalignitem.hxx index 335b15f3769b..c58274b8fe16 100644 --- a/include/editeng/paravertalignitem.hxx +++ b/include/editeng/paravertalignitem.hxx @@ -37,8 +37,7 @@ public: enum class Align { Automatic, Baseline, Top, Center, Bottom }; static SfxPoolItem* CreateDefault(); - SvxParaVertAlignItem( Align nValue /*= 0*/, - const sal_uInt16 nId ); + SvxParaVertAlignItem( Align nValue /*= 0*/, TypedWhichId<SvxParaVertAlignItem> nId ); virtual SvxParaVertAlignItem* Clone( SfxItemPool *pPool = nullptr ) const override; diff --git a/include/editeng/writingmodeitem.hxx b/include/editeng/writingmodeitem.hxx index f9e116d76897..d01be0e41495 100644 --- a/include/editeng/writingmodeitem.hxx +++ b/include/editeng/writingmodeitem.hxx @@ -29,7 +29,7 @@ class EDITENG_DLLPUBLIC SvxWritingModeItem final : public SfxUInt16Item { public: SvxWritingModeItem( css::text::WritingMode eValue /*= css::text::WritingMode_LR_TB*/, - sal_uInt16 nWhich /*= SDRATTR_TEXTDIRECTION*/ ); + TypedWhichId<SvxWritingModeItem> nWhich /*= SDRATTR_TEXTDIRECTION*/ ); virtual ~SvxWritingModeItem() override; SvxWritingModeItem(SvxWritingModeItem const &) = default; diff --git a/include/sfx2/sfxsids.hrc b/include/sfx2/sfxsids.hrc index 847dc6dac174..59b98b15244e 100644 --- a/include/sfx2/sfxsids.hrc +++ b/include/sfx2/sfxsids.hrc @@ -253,7 +253,7 @@ class SvxZoomItem; #define SID_DOC_HIERARCHICALNAME TypedWhichId<SfxStringItem>(SID_SFX_START + 1701) #define SID_TERMINATE_INPLACEACTIVATION (SID_SFX_START + 1702) #define SID_APPLY_STYLE (SID_SFX_START + 1703) -#define SID_MACRO_SIGNATURE (SID_SFX_START + 1704) +#define SID_MACRO_SIGNATURE TypedWhichId<SfxUInt16Item>(SID_SFX_START + 1704) #define SID_ATTR_WARNALIENFORMAT TypedWhichId<SfxBoolItem>(SID_SFX_START + 1705) #define SID_COPY_STREAM_IF_POSSIBLE TypedWhichId<SfxBoolItem>(SID_SFX_START + 1706) #define SID_MAIL_SENDDOCASFORMAT (SID_SFX_START + 1707) @@ -377,7 +377,7 @@ class SvxZoomItem; #define SID_STYLE_NEW_BY_EXAMPLE TypedWhichId<SfxStringItem>(SID_SFX_START + 555) #define SID_STYLE_UPDATE_BY_EXAMPLE TypedWhichId<SfxStringItem>(SID_SFX_START + 556) #define SID_STYLE_DRAGHIERARCHIE (SID_SFX_START + 565) -#define SID_STYLE_MASK (SID_SFX_START + 562) +#define SID_STYLE_MASK TypedWhichId<SfxUInt16Item>(SID_SFX_START + 562) #define SID_STYLE_PREVIEW (SID_SFX_START + 567) #define SID_STYLE_END_PREVIEW (SID_SFX_START + 568) #define SID_STYLE_HIDE TypedWhichId<SfxStringItem>(SID_SFX_START + 1603) @@ -519,7 +519,7 @@ class SvxZoomItem; #define SID_VERB_START (SID_SFX_START + 1100) #define SID_VERB_END (SID_SFX_START + 1121) -#define SID_SIGNATURE (SID_SFX_START + 1643) +#define SID_SIGNATURE TypedWhichId<SfxUInt16Item>(SID_SFX_START + 1643) // SaveTabPage #define SID_ATTR_DOCINFO TypedWhichId<SfxBoolItem>(SID_OPTIONS_START + 0) @@ -589,7 +589,7 @@ class SvxZoomItem; #define SID_SIZE_REAL (SID_SVX_START + 99) #define SID_SIZE_PAGE (SID_SVX_START + 100) #define SID_GALLERY_BG_BRUSH (SID_SVX_START + 279) -#define SID_SEARCH_OPTIONS (SID_SVX_START + 281) +#define SID_SEARCH_OPTIONS TypedWhichId<SfxUInt16Item>(SID_SVX_START + 281) #define SID_SEARCH_ITEM TypedWhichId<SvxSearchItem>(SID_SVX_START + 291) #define SID_SIDEBAR TypedWhichId<SfxBoolItem>(SID_SVX_START + 336) #define SID_NOTEBOOKBAR TypedWhichId<SfxStringItem>(SID_SVX_START + 338) diff --git a/include/sfx2/zoomitem.hxx b/include/sfx2/zoomitem.hxx index 4e7703dfdf92..fa1fd9b9d7e8 100644 --- a/include/sfx2/zoomitem.hxx +++ b/include/sfx2/zoomitem.hxx @@ -61,7 +61,7 @@ public: static SfxPoolItem* CreateDefault(); SvxZoomItem( SvxZoomType eZoomType = SvxZoomType::PERCENT, - sal_uInt16 nVal = 0, sal_uInt16 nWhich = SID_ATTR_ZOOM ); + sal_uInt16 nVal = 0, TypedWhichId<SvxZoomItem> nWhich = SID_ATTR_ZOOM ); void SetValueSet( SvxZoomEnableFlags nValues ) { nValueSet = nValues; } SvxZoomEnableFlags GetValueSet() const { return nValueSet; } diff --git a/include/svx/svxids.hrc b/include/svx/svxids.hrc index a07a6f133120..e7c9b250d718 100644 --- a/include/svx/svxids.hrc +++ b/include/svx/svxids.hrc @@ -35,6 +35,7 @@ class SfxIntegerListItem; class SfxPointItem; class SfxRectangleItem; class SfxStringItem; +class SfxUInt16Item; class SfxUInt32Item; class SvxBitmapListItem; class SvxBoxInfoItem; @@ -136,7 +137,7 @@ class XFillGradientItem; #define SID_BEZIER_ELIMINATE_POINTS (SID_SD_START+30) #define SID_BEZIER_EDGE (SID_SD_START+66) #define SID_BEZIER_SYMMTR (SID_SD_START+67) -#define SID_TEXTEDIT (SID_SD_START+76) +#define SID_TEXTEDIT TypedWhichId<SfxUInt16Item>(SID_SD_START+76) #define SID_ENTER_GROUP (SID_SD_START+96) #define SID_LEAVE_GROUP (SID_SD_START+97) #define SID_SIZE_PAGE_WIDTH (SID_SD_START+98) @@ -181,9 +182,9 @@ class XFillGradientItem; #define FN_NUM_BULLET_OFF (FN_EDIT + 37) // numbering off #define FN_NUM_BULLET_ON (FN_EDIT + 38) // numbering with bullets on #define FN_NUM_NUMBERING_ON (FN_EDIT + 44) // numbering on -#define FN_BUL_NUM_RULE_INDEX (FN_EDIT + 120) // achieving num rule index -#define FN_NUM_NUM_RULE_INDEX (FN_EDIT + 121) -#define FN_OUTLINE_RULE_INDEX (FN_EDIT + 122) +#define FN_BUL_NUM_RULE_INDEX TypedWhichId<SfxUInt16Item>(FN_EDIT + 120) // achieving num rule index +#define FN_NUM_NUM_RULE_INDEX TypedWhichId<SfxUInt16Item>(FN_EDIT + 121) +#define FN_OUTLINE_RULE_INDEX TypedWhichId<SfxUInt16Item>(FN_EDIT + 122) #define FN_INSERT (SID_SW_START + 300) // 20300 #define FN_DELETE_BOOKMARK TypedWhichId<SfxStringItem>(FN_INSERT + 1) @@ -518,7 +519,7 @@ class XFillGradientItem; #define SID_TABLEDESIGN ( SID_SVX_START + 429 ) #define SID_GENERAL_OPTIONS ( SID_SVX_START + 432 ) -#define SID_SW_EDITOPTIONS ( SID_SVX_START + 433 ) +#define SID_SW_EDITOPTIONS TypedWhichId<SfxUInt16Item>( SID_SVX_START + 433 ) #define SID_SD_EDITOPTIONS ( SID_SVX_START + 434 ) #define SID_SC_EDITOPTIONS ( SID_SVX_START + 435 ) #define SID_SM_EDITOPTIONS ( SID_SVX_START + 436 ) @@ -559,7 +560,7 @@ class XFillGradientItem; #define SID_GRFFILTER_POPART ( SID_SVX_START + 478 ) #define SID_GRFFILTER_SEPIA ( SID_SVX_START + 479 ) #define SID_GRFFILTER_SOLARIZE ( SID_SVX_START + 480 ) -#define SID_FIELD_GRABFOCUS ( SID_SVX_START + 567 ) +#define SID_FIELD_GRABFOCUS TypedWhichId<SfxUInt16Item>( SID_SVX_START + 567 ) #define SID_ATTR_ALIGN_DEGREES ( SID_SVX_START + 577 ) #define SID_ATTR_ALIGN_LOCKPOS ( SID_SVX_START + 578 ) #define SID_ATTR_NUMBERFORMAT_ONE_AREA TypedWhichId<SfxBoolItem>( SID_SVX_START + 580 ) @@ -614,7 +615,7 @@ class XFillGradientItem; #define SID_FM_CREATE_CONTROL ( SID_SVX_START + 628 ) #define SID_FM_DESIGN_MODE TypedWhichId<SfxBoolItem>( SID_SVX_START + 629 ) #define SID_FM_RECORD_UNDO ( SID_SVX_START + 630 ) -#define SID_FM_CONTROL_IDENTIFIER ( SID_SVX_START + 631 ) +#define SID_FM_CONTROL_IDENTIFIER TypedWhichId<SfxUInt16Item>( SID_SVX_START + 631 ) #define SID_FM_CONTROL_INVENTOR ( SID_SVX_START + 632 ) #define SID_FM_SHOW_FMEXPLORER ( SID_SVX_START + 633 ) #define SID_FM_FIELDS_CONTROL ( SID_SVX_START + 634 ) @@ -849,9 +850,9 @@ class XFillGradientItem; #define SID_ATTR_BORDER_DIAG_BLTR ( SID_SVX_START + 1014 ) #define SID_ATTR_ALIGN_SHRINKTOFIT ( SID_SVX_START + 1015 ) #define SID_CHINESE_CONVERSION ( SID_SVX_START + 1016 ) -#define SID_PAGE_TYPE ( SID_SVX_START + 1017 ) -#define SID_DLG_TYPE ( SID_SVX_START + 1018 ) -#define SID_TABPAGE_POS ( SID_SVX_START + 1019 ) +#define SID_PAGE_TYPE TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1017 ) +#define SID_DLG_TYPE TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1018 ) +#define SID_TABPAGE_POS TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1019 ) #define SID_GRAPHIC ( SID_SVX_START + 1020 ) #define SID_OBJECT_LIST TypedWhichId<OfaPtrItem>( SID_SVX_START + 1021 ) #define SID_ATTR_SET ( SID_SVX_START + 1022 ) @@ -861,14 +862,14 @@ class XFillGradientItem; #define SID_BULLET_CHAR_FMT TypedWhichId<SfxStringItem>( SID_SVX_START + 1026 ) #define SID_DISABLE_SVXEXTPARAGRAPHTABPAGE_PAGEBREAK ( SID_SVX_START + 1027 ) #define SID_SVXPARAALIGNTABPAGE_ENABLEJUSTIFYEXT ( SID_SVX_START + 1028 ) -#define SID_SVXSTDPARAGRAPHTABPAGE_PAGEWIDTH ( SID_SVX_START + 1029 ) +#define SID_SVXSTDPARAGRAPHTABPAGE_PAGEWIDTH TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1029 ) #define SID_SVXSTDPARAGRAPHTABPAGE_FLAGSET ( SID_SVX_START + 1030 ) #define SID_SVXSTDPARAGRAPHTABPAGE_ABSLINEDIST ( SID_SVX_START + 1031 ) -#define SID_SVXTABULATORTABPAGE_DISABLEFLAGS ( SID_SVX_START + 1032 ) +#define SID_SVXTABULATORTABPAGE_DISABLEFLAGS TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1032 ) #define SID_SVXTEXTATTRPAGE_OBJKIND ( SID_SVX_START + 1033 ) #define SID_FLAG_TYPE ( SID_SVX_START + 1034 ) -#define SID_SWMODE_TYPE ( SID_SVX_START + 1035 ) -#define SID_DISABLE_CTL ( SID_SVX_START + 1036 ) +#define SID_SWMODE_TYPE TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1035 ) +#define SID_DISABLE_CTL TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1036 ) #define SID_INSERT_HYPERLINKCONTROL ( SID_SVX_START + 1037 ) #define SID_ENUM_PAGE_MODE TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1038 ) #define SID_PAPER_START TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1039 ) @@ -970,8 +971,8 @@ class XFillGradientItem; #define SID_CHAR_DLG_EFFECT ( SID_SVX_START + 1133 ) #define SID_CHAR_DLG_POSITION ( SID_SVX_START + 1134 ) #define SID_ATTR_FILL_USE_SLIDE_BACKGROUND ( SID_SVX_START + 1135 ) -#define FN_SVX_SET_NUMBER ( SID_SVX_START + 1136 ) -#define FN_SVX_SET_BULLET ( SID_SVX_START + 1137 ) +#define FN_SVX_SET_NUMBER TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1136 ) +#define FN_SVX_SET_BULLET TypedWhichId<SfxUInt16Item>( SID_SVX_START + 1137 ) #define FN_SVX_SET_OUTLINE ( SID_SVX_START + 1138 ) #define SID_ATTR_BORDER_STYLES TypedWhichId<SfxIntegerListItem>( SID_SVX_START + 1140 ) |