summaryrefslogtreecommitdiff
path: root/chart2/source/controller/dialogs/dlg_ChartType.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'chart2/source/controller/dialogs/dlg_ChartType.cxx')
-rw-r--r--chart2/source/controller/dialogs/dlg_ChartType.cxx11
1 files changed, 9 insertions, 2 deletions
diff --git a/chart2/source/controller/dialogs/dlg_ChartType.cxx b/chart2/source/controller/dialogs/dlg_ChartType.cxx
index 30d03d140def..073d194a3afd 100644
--- a/chart2/source/controller/dialogs/dlg_ChartType.cxx
+++ b/chart2/source/controller/dialogs/dlg_ChartType.cxx
@@ -42,7 +42,8 @@ ChartTypeDialog::ChartTypeDialog( vcl::Window* pParent
, m_xChartModel(xChartModel)
, m_xCC( xContext )
{
- m_pChartTypeTabPage = new ChartTypeTabPage(
+ m_pChartTypeTabPage = VclPtr<ChartTypeTabPage>::Create(
+
get_content_area(),
uno::Reference<XChartDocument>::query(m_xChartModel),
m_xCC,
@@ -55,7 +56,13 @@ ChartTypeDialog::ChartTypeDialog( vcl::Window* pParent
ChartTypeDialog::~ChartTypeDialog()
{
- delete m_pChartTypeTabPage;
+ disposeOnce();
+}
+
+void ChartTypeDialog::dispose()
+{
+ m_pChartTypeTabPage.disposeAndClear();
+ ModalDialog::dispose();
}
} //namespace chart