diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-12-23 16:03:53 +0200 |
---|---|---|
committer | Jochen Nitschke <j.nitschke+logerrit@ok.de> | 2016-12-26 18:35:59 +0000 |
commit | 833e6ca9d284bca536d09f6a30b1a8cfbb1c86d8 (patch) | |
tree | bd620398e39c9b2b84bb6127fa58575440193a80 /include | |
parent | d6a7f7fe98af19b43d8e82555a10bf1e835d0533 (diff) |
use std::vector instead of naked array in SfxItemPool
Change-Id: I2d4ac010ff5818e673567cee05700872588918e4
Reviewed-on: https://gerrit.libreoffice.org/32384
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/svl/itempool.hxx | 7 | ||||
-rw-r--r-- | include/svx/xpool.hxx | 4 |
2 files changed, 6 insertions, 5 deletions
diff --git a/include/svl/itempool.hxx b/include/svl/itempool.hxx index 7255bc7f1206..33449286c7da 100644 --- a/include/svl/itempool.hxx +++ b/include/svl/itempool.hxx @@ -25,6 +25,7 @@ #include <svl/svldllapi.h> #include <tools/solar.h> #include <memory> +#include <vector> class SvStream; class SfxBroadcaster; @@ -90,7 +91,7 @@ public: SfxItemPool( const OUString &rName, sal_uInt16 nStart, sal_uInt16 nEnd, const SfxItemInfo *pItemInfos, - SfxPoolItem **pDefaults = nullptr, + std::vector<SfxPoolItem*> *pDefaults = nullptr, bool bLoadRefCounts = true ); protected: @@ -105,9 +106,9 @@ public: const SfxPoolItem* GetPoolDefaultItem( sal_uInt16 nWhich ) const; void ResetPoolDefaultItem( sal_uInt16 nWhich ); - void SetDefaults( SfxPoolItem **pDefaults ); + void SetDefaults( std::vector<SfxPoolItem*>* pDefaults ); void ReleaseDefaults( bool bDelete = false ); - static void ReleaseDefaults( SfxPoolItem **pDefaults, sal_uInt16 nCount, bool bDelete = false ); + static void ReleaseDefaults( std::vector<SfxPoolItem*> *pDefaults, bool bDelete = false ); virtual MapUnit GetMetric( sal_uInt16 nWhich ) const; void SetDefaultMetric( MapUnit eNewMetric ); diff --git a/include/svx/xpool.hxx b/include/svx/xpool.hxx index 364b91db3e4c..5e6dd21efab3 100644 --- a/include/svx/xpool.hxx +++ b/include/svx/xpool.hxx @@ -33,8 +33,8 @@ class SVX_DLLPUBLIC XOutdevItemPool : public SfxItemPool { protected: - SfxPoolItem** mppLocalPoolDefaults; - SfxItemInfo* mpLocalItemInfos; + std::vector<SfxPoolItem*>* mpLocalPoolDefaults; + SfxItemInfo* mpLocalItemInfos; public: XOutdevItemPool( SfxItemPool* pMaster, bool bLoadRefCounts = true); |