summaryrefslogtreecommitdiff
path: root/chart2/source/controller/dialogs/dlg_CreationWizard.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'chart2/source/controller/dialogs/dlg_CreationWizard.cxx')
-rw-r--r--chart2/source/controller/dialogs/dlg_CreationWizard.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/chart2/source/controller/dialogs/dlg_CreationWizard.cxx b/chart2/source/controller/dialogs/dlg_CreationWizard.cxx
index ccf2cdc5221f..2bdedc962856 100644
--- a/chart2/source/controller/dialogs/dlg_CreationWizard.cxx
+++ b/chart2/source/controller/dialogs/dlg_CreationWizard.cxx
@@ -68,6 +68,10 @@ CreationWizard::CreationWizard(weld::Window* pParent, const uno::Reference<frame
declarePath(PATH_FULL, aPath);
+ m_pTemplateProvider = static_cast<ChartTypeTabPage*>(GetOrCreatePage(STATE_CHARTTYPE));
+ assert(m_pTemplateProvider && "must exist");
+ m_pDialogModel->setTemplate(m_pTemplateProvider->getCurrentTemplate());
+
SetRoadmapHelpId(HID_SCH_WIZARD_ROADMAP);
if (!m_pDialogModel->getModel().isDataFromSpreadsheet())
@@ -97,9 +101,6 @@ std::unique_ptr<BuilderPage> CreationWizard::createPage(WizardState nState)
{
m_aTimerTriggeredControllerLock.startTimer();
xRet = std::make_unique<ChartTypeTabPage>(pPageContainer, this, m_xChartModel);
- m_pTemplateProvider = static_cast<ChartTypeTabPage*>(xRet.get());
- if (m_pDialogModel)
- m_pDialogModel->setTemplate( m_pTemplateProvider->getCurrentTemplate());
break;
}
case STATE_SIMPLE_RANGE: