diff options
author | Caolán McNamara <caolanm@redhat.com> | 2019-12-11 20:57:45 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2019-12-12 21:12:10 +0100 |
commit | 2431477337f4ac4384ba615f76bfb5904f1a3b47 (patch) | |
tree | 6f676441983e9b3c8440600d09a49478353e1faf /sc/source/ui/inc | |
parent | 23cfd3d1004f5ddda8cd79878c00b6c64f20068c (diff) |
use covariant return type for SfxPoolItem::Clone
and can then remove some casting
Change-Id: Id821c32ca2cbcdb7f57ef7a5fa1960042e630ffc
Reviewed-on: https://gerrit.libreoffice.org/85022
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc/source/ui/inc')
-rw-r--r-- | sc/source/ui/inc/condformatdlgitem.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/uiitems.hxx | 18 |
2 files changed, 10 insertions, 10 deletions
diff --git a/sc/source/ui/inc/condformatdlgitem.hxx b/sc/source/ui/inc/condformatdlgitem.hxx index 89523b9c237b..52c4f4ddc944 100644 --- a/sc/source/ui/inc/condformatdlgitem.hxx +++ b/sc/source/ui/inc/condformatdlgitem.hxx @@ -48,7 +48,7 @@ public: ScCondFormatDlgItem & operator =(ScCondFormatDlgItem &&) = delete; // due to SfxPoolItem virtual bool operator==(const SfxPoolItem&) const override; - virtual SfxPoolItem* Clone(SfxItemPool* pPool = nullptr) const override; + virtual ScCondFormatDlgItem* Clone(SfxItemPool* pPool = nullptr) const override; bool IsManaged() const; condformat::dialog::ScCondFormatDialogType GetDialogType() const; diff --git a/sc/source/ui/inc/uiitems.hxx b/sc/source/ui/inc/uiitems.hxx index 7ed2c35c6233..5c4284101215 100644 --- a/sc/source/ui/inc/uiitems.hxx +++ b/sc/source/ui/inc/uiitems.hxx @@ -62,7 +62,7 @@ public: virtual ~ScInputStatusItem() override; virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScInputStatusItem* Clone( SfxItemPool *pPool = nullptr ) const override; const ScAddress& GetPos() const { return aCursorPos; } @@ -135,7 +135,7 @@ public: const ScSortParam* pSortData ); virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScSortItem* Clone( SfxItemPool *pPool = nullptr ) const override; virtual bool QueryValue( css::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const override; ScViewData* GetViewData () const { return pViewData; } @@ -158,7 +158,7 @@ public: virtual ~ScQueryItem() override; virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScQueryItem* Clone( SfxItemPool *pPool = nullptr ) const override; ScViewData* GetViewData () const { return pViewData; } const ScQueryParam& GetQueryData() const; @@ -183,7 +183,7 @@ public: const ScSubTotalParam* pSubTotalData ); virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScSubTotalItem* Clone( SfxItemPool *pPool = nullptr ) const override; virtual bool QueryValue( css::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const override; ScViewData* GetViewData () const { return pViewData; } @@ -202,7 +202,7 @@ public: virtual ~ScUserListItem() override; virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScUserListItem* Clone( SfxItemPool *pPool = nullptr ) const override; void SetUserList ( const ScUserList& rUserList ); ScUserList* GetUserList () const { return pUserList.get(); } @@ -218,7 +218,7 @@ public: const ScConsolidateParam* pParam ); virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScConsolidateItem* Clone( SfxItemPool *pPool = nullptr ) const override; const ScConsolidateParam& GetData() const { return theConsData; } @@ -235,7 +235,7 @@ public: virtual ~ScPivotItem() override; virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScPivotItem* Clone( SfxItemPool *pPool = nullptr ) const override; const ScDPSaveData& GetData() const { return *pSaveData; } const ScRange& GetDestRange() const { return aDestRange; } @@ -254,7 +254,7 @@ public: const ScSolveParam* pParam ); virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScSolveItem* Clone( SfxItemPool *pPool = nullptr ) const override; const ScSolveParam& GetData() const { return theSolveData; } @@ -269,7 +269,7 @@ public: const ScTabOpParam* pParam ); virtual bool operator==( const SfxPoolItem& ) const override; - virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + virtual ScTabOpItem* Clone( SfxItemPool *pPool = nullptr ) const override; const ScTabOpParam& GetData() const { return theTabOpData; } |