29#define WID_CHAOS_START TypedWhichId<SfxStringItem>(500)
36class CntStaticPoolDefaults_Impl
38 static const sal_uInt32 m_nItems = 1;
39 std::vector<SfxPoolItem*> mvDefaults;
40 std::unique_ptr<SfxItemInfo[]> m_pItemInfos;
46 explicit CntStaticPoolDefaults_Impl();
47 ~CntStaticPoolDefaults_Impl();
48 CntStaticPoolDefaults_Impl(
const CntStaticPoolDefaults_Impl&) =
delete;
49 CntStaticPoolDefaults_Impl& operator=(
const CntStaticPoolDefaults_Impl&) =
delete;
51 std::vector<SfxPoolItem*>* GetDefaults() {
return &mvDefaults; }
52 const SfxItemInfo* GetItemInfos()
const {
return m_pItemInfos.get(); }
58 static CntItemPool* _pThePool;
63 virtual ~CntItemPool()
override;
66 static CntItemPool* Acquire();
67 static sal_uInt16 Release();
76 return CntItemPool::Acquire();
84 return CntItemPool::Release();
94CntItemPool* CntItemPool::_pThePool =
nullptr;
97CntItemPool::CntItemPool()
115CntItemPool::~CntItemPool()
123CntItemPool* CntItemPool::Acquire()
126 _pThePool =
new CntItemPool;
135sal_uInt16 CntItemPool::Release()
140 sal_uInt16& nRefs = _pThePool->_nRefs;
161inline void CntStaticPoolDefaults_Impl::Insert(
166 mvDefaults[
nPos ] = pItem;
167 m_pItemInfos[
nPos ]._nSID = 0;
168 m_pItemInfos[
nPos ]._bPoolable =
true;
172CntStaticPoolDefaults_Impl::~CntStaticPoolDefaults_Impl()
174 for ( sal_uInt32 n = 0;
n < m_nItems; ++
n )
175 delete mvDefaults[ n ];
179CntStaticPoolDefaults_Impl::CntStaticPoolDefaults_Impl()
180: mvDefaults( m_nItems, nullptr ),
183 memset( m_pItemInfos.get(), 0,
sizeof(
SfxItemInfo ) * m_nItems );
static SfxItemPool * GetItemPool()
static sal_uInt16 ReleaseItemPool()
virtual void Insert(SotClipboardFormatId nFormat, const OUString &rFormatName) override
static CntStaticPoolDefaults_Impl * pPoolDefs_Impl