diff options
Diffstat (limited to 'sc/source/ui/attrdlg/tabpages.cxx')
-rw-r--r-- | sc/source/ui/attrdlg/tabpages.cxx | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/sc/source/ui/attrdlg/tabpages.cxx b/sc/source/ui/attrdlg/tabpages.cxx index 2202754e7192..163b8742fc4c 100644 --- a/sc/source/ui/attrdlg/tabpages.cxx +++ b/sc/source/ui/attrdlg/tabpages.cxx @@ -59,9 +59,23 @@ ScTabPageProtection::ScTabPageProtection(vcl::Window* pParent, const SfxItemSet& m_pBtnHidePrint->SetClickHdl( LINK( this, ScTabPageProtection, ButtonClickHdl ) ); } -SfxTabPage* ScTabPageProtection::Create( vcl::Window* pParent, const SfxItemSet* rAttrSet ) +ScTabPageProtection::~ScTabPageProtection() { - return ( new ScTabPageProtection( pParent, *rAttrSet ) ); + disposeOnce(); +} + +void ScTabPageProtection::dispose() +{ + m_pBtnHideCell.clear(); + m_pBtnProtect.clear(); + m_pBtnHideFormula.clear(); + m_pBtnHidePrint.clear(); + SfxTabPage::dispose(); +} + +VclPtr<SfxTabPage> ScTabPageProtection::Create( vcl::Window* pParent, const SfxItemSet* rAttrSet ) +{ + return VclPtr<SfxTabPage>( new ScTabPageProtection( pParent, *rAttrSet ), SAL_NO_ACQUIRE ); } void ScTabPageProtection::Reset( const SfxItemSet* rCoreAttrs ) |