diff options
-rw-r--r-- | sfx2/source/dialog/templdlg.cxx | 6 | ||||
-rw-r--r-- | sfx2/source/inc/templdgi.hxx | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx index fc1e0753c308..204a7346d6d5 100644 --- a/sfx2/source/dialog/templdlg.cxx +++ b/sfx2/source/dialog/templdlg.cxx @@ -861,7 +861,7 @@ SfxCommonTemplateDialog_Impl::~SfxCommonTemplateDialog_Impl() EndListening(*pStyleSheetPool); pStyleSheetPool = nullptr; pTreeBox.disposeAndClear(); - delete pIdle; + pIdle.reset(); if ( m_pDeletionWatcher ) m_pDeletionWatcher->signal(); aFmtLb.disposeAndClear(); @@ -1402,7 +1402,7 @@ IMPL_LINK_NOARG( SfxCommonTemplateDialog_Impl, TimeOut, Timer *, void ) } } bDontUpdate=false; - DELETEZ(pIdle); + pIdle.reset(); } else pIdle->Start(); @@ -1488,7 +1488,7 @@ void SfxCommonTemplateDialog_Impl::Notify(SfxBroadcaster& /*rBC*/, const SfxHint { if(!pIdle) { - pIdle=new Idle("SfxCommonTemplate"); + pIdle.reset(new Idle("SfxCommonTemplate")); pIdle->SetPriority(TaskPriority::LOWEST); pIdle->SetInvokeHandler(LINK(this,SfxCommonTemplateDialog_Impl,TimeOut)); } diff --git a/sfx2/source/inc/templdgi.hxx b/sfx2/source/inc/templdgi.hxx index 4a911d292003..381da18b8916 100644 --- a/sfx2/source/inc/templdgi.hxx +++ b/sfx2/source/inc/templdgi.hxx @@ -176,7 +176,7 @@ protected: VclPtr<PopupMenu> mxMenu; OString sLastItemIdent; SfxModule* pModule; - Idle* pIdle; + std::unique_ptr<Idle> pIdle; SfxStyleFamilies* pStyleFamilies; SfxTemplateItem* pFamilyState[MAX_FAMILIES]; |