Commit 11dde672 authored by hjk's avatar hjk Committed by hjk
Browse files

qmlprofiler: instantiate docks when using the toolbar

Change-Id: Ic839a4cf18494115a9a9ace4738ecb163722c40b
Reviewed-on: http://codereview.qt.nokia.com/1244

Reviewed-by: default avatarQt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: default avatarhjk <qthjk@ovi.com>
parent 378da003
...@@ -227,6 +227,14 @@ IAnalyzerEngine *QmlProfilerTool::createEngine(const AnalyzerStartParameters &sp ...@@ -227,6 +227,14 @@ IAnalyzerEngine *QmlProfilerTool::createEngine(const AnalyzerStartParameters &sp
void QmlProfilerTool::initializeDockWidgets() void QmlProfilerTool::initializeDockWidgets()
{ {
ensureWidgets();
}
void QmlProfilerTool::ensureWidgets()
{
if (d->m_traceWindow)
return;
Utils::FancyMainWindow *mw = AnalyzerManager::mainWindow(); Utils::FancyMainWindow *mw = AnalyzerManager::mainWindow();
d->m_traceWindow = new TraceWindow(mw); d->m_traceWindow = new TraceWindow(mw);
...@@ -297,6 +305,8 @@ void QmlProfilerTool::toolDeselected() ...@@ -297,6 +305,8 @@ void QmlProfilerTool::toolDeselected()
QWidget *QmlProfilerTool::createControlWidget() QWidget *QmlProfilerTool::createControlWidget()
{ {
ensureWidgets();
// custom toolbar (TODO) // custom toolbar (TODO)
QWidget *toolbarWidget = new QWidget; QWidget *toolbarWidget = new QWidget;
toolbarWidget->setObjectName(QLatin1String("QmlProfilerToolBarWidget")); toolbarWidget->setObjectName(QLatin1String("QmlProfilerToolBarWidget"));
......
...@@ -91,6 +91,7 @@ private: ...@@ -91,6 +91,7 @@ private:
void updateAttachAction(bool isCurrentTool); void updateAttachAction(bool isCurrentTool);
void connectToClient(); void connectToClient();
void updateRecordingState(); void updateRecordingState();
void ensureWidgets();
class QmlProfilerToolPrivate; class QmlProfilerToolPrivate;
QmlProfilerToolPrivate *d; QmlProfilerToolPrivate *d;
......
Supports Markdown
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