Create RunConfiguration specific QmlProfilerWorkerFactories

Instead of relying on the QmlProfilerRunWorkerFactory to match for all
RunConfiguration, every plugin needs to create a WorkerFactory for
its own RunConfiguration.

Similar to the SimpleTargetRunnerFactory there is now a
SimpleQmlProfilerRunnerFactory which makes the setup easy.

Change-Id: I504ca5afe232cb4e3aa0bb0b67271637a7e7a9d0
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Dominik Holland
2024-01-17 10:25:21 +01:00
parent fca33684a7
commit 1d2ed65d93
4 changed files with 29 additions and 1 deletions

View File

@@ -33,6 +33,8 @@
#include <projectexplorer/projectmanager.h>
#include <projectexplorer/target.h>
#include <qmlprofiler/qmlprofilerruncontrol.h>
#include <qmljs/qmljsmodelmanagerinterface.h>
#include <qmljseditor/qmljseditor.h>
@@ -57,6 +59,7 @@
#include <QTimer>
using namespace Core;
using namespace QmlProfiler;
using namespace Debugger;
using namespace ProjectExplorer;
using namespace Utils;
@@ -101,6 +104,7 @@ public:
QmlProjectRunConfigurationFactory runConfigFactory;
SimpleTargetRunnerFactory runWorkerFactory{{runConfigFactory.runConfigurationId()}};
SimpleDebugRunnerFactory debugRunWorkerFactory{{runConfigFactory.runConfigurationId()}};
SimpleQmlProfilerRunnerFactory qmlProfilerRunWorkerFactory{{runConfigFactory.runConfigurationId()}};
QPointer<QMessageBox> lastMessageBox;
QdsLandingPage *landingPage = nullptr;
QdsLandingPageWidget *landingPageWidget = nullptr;