Commit ce28e362 authored by Tobias Hunger's avatar Tobias Hunger

QmlDesigner: Plug mem leak when design mode is not opened

Change-Id: I4917dd3dd1d85b7eb35dce50d2283ac2039c0a2e
Reviewed-by: default avatarThomas Hartmann <Thomas.Hartmann@digia.com>
Reviewed-by: default avatarTobias Hunger <tobias.hunger@digia.com>
parent c71e8998
......@@ -174,6 +174,8 @@ DesignModeWidget::DesignModeWidget(QWidget *parent) :
m_mainSplitter(0),
m_toolBar(Core::EditorManager::createToolBar(this)),
m_crumbleBar(new CrumbleBar(this)),
m_outputPanePlaceholder(0),
m_outputPlaceholderSplitter(0),
m_isDisabled(false),
m_showSidebars(true),
m_initStatus(NotInitialized),
......@@ -181,8 +183,6 @@ DesignModeWidget::DesignModeWidget(QWidget *parent) :
m_navigatorHistoryCounter(-1),
m_keepNavigatorHistory(false)
{
m_outputPlaceholderSplitter = new Core::MiniSplitter;
m_outputPanePlaceholder = new StyledOutputpanePlaceHolder(Core::DesignMode::instance(), m_outputPlaceholderSplitter);
}
DesignModeWidget::~DesignModeWidget()
......@@ -554,6 +554,9 @@ QWidget *DesignModeWidget::createCenterWidget()
}
// editor and output panes
m_outputPlaceholderSplitter = new Core::MiniSplitter;
m_outputPanePlaceholder = new StyledOutputpanePlaceHolder(Core::DesignMode::instance(), m_outputPlaceholderSplitter);
if (centralWidgetInfos.count() == 1)
m_outputPlaceholderSplitter->addWidget(centralWidgetInfos.first().widget);
else
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment