summaryrefslogtreecommitdiff
path: root/sc/source/ui/optdlg/tpview.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui/optdlg/tpview.cxx')
-rw-r--r--sc/source/ui/optdlg/tpview.cxx22
1 files changed, 8 insertions, 14 deletions
diff --git a/sc/source/ui/optdlg/tpview.cxx b/sc/source/ui/optdlg/tpview.cxx
index c26ff3bacfe1..0fff707bac20 100644
--- a/sc/source/ui/optdlg/tpview.cxx
+++ b/sc/source/ui/optdlg/tpview.cxx
@@ -87,19 +87,13 @@ ScTpContentOptions::ScTpContentOptions(TabPageParent pParent, const SfxItemSet&
ScTpContentOptions::~ScTpContentOptions()
{
- disposeOnce();
-}
-
-void ScTpContentOptions::dispose()
-{
m_xColorLB.reset();
- SfxTabPage::dispose();
}
-VclPtr<SfxTabPage> ScTpContentOptions::Create( TabPageParent pParent,
+std::unique_ptr<SfxTabPage> ScTpContentOptions::Create( TabPageParent pParent,
const SfxItemSet* rCoreSet )
{
- return VclPtr<ScTpContentOptions>::Create(pParent, *rCoreSet);
+ return std::make_unique<ScTpContentOptions>(pParent, *rCoreSet);
}
bool ScTpContentOptions::FillItemSet( SfxItemSet* rCoreSet )
@@ -359,15 +353,15 @@ ScTpLayoutOptions::~ScTpLayoutOptions()
{
}
-VclPtr<SfxTabPage> ScTpLayoutOptions::Create( TabPageParent pParent,
+std::unique_ptr<SfxTabPage> ScTpLayoutOptions::Create( TabPageParent pParent,
const SfxItemSet* rCoreSet )
{
- VclPtrInstance<ScTpLayoutOptions> pNew( pParent, *rCoreSet );
- ScDocShell* pDocSh = dynamic_cast< ScDocShell *>( SfxObjectShell::Current() );
+ auto xNew = std::make_unique<ScTpLayoutOptions>(pParent, *rCoreSet);
- if(pDocSh!=nullptr)
- pNew->pDoc = &pDocSh->GetDocument();
- return pNew;
+ ScDocShell* pDocSh = dynamic_cast< ScDocShell *>( SfxObjectShell::Current() );
+ if (pDocSh!=nullptr)
+ xNew->pDoc = &pDocSh->GetDocument();
+ return xNew;
}
bool ScTpLayoutOptions::FillItemSet( SfxItemSet* rCoreSet )