forked from qt-creator/qt-creator
Create RunConfiguration specific DebugWorkerFactories
Instead of relying on the DebuggerRunWorkerFactory to match for all RunConfiguration, every plugin needs to create a WorkerFactory for its own RunConfiguration. Similar to the SimpleTargetRunnerFactory there is now a SimpleDebugRunnerFactory which makes the setup easy. Change-Id: I25aaabcd70f7ac649baeab4eb4c7e88d53dac91e Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -13,6 +13,8 @@
|
||||
#include "pythontr.h"
|
||||
#include "pythonwizardpage.h"
|
||||
|
||||
#include <debugger/debuggerruncontrol.h>
|
||||
|
||||
#include <extensionsystem/iplugin.h>
|
||||
|
||||
#include <projectexplorer/buildtargetinfo.h>
|
||||
@@ -25,6 +27,7 @@
|
||||
#include <utils/fsengine/fileiconprovider.h>
|
||||
#include <utils/theme/theme.h>
|
||||
|
||||
using namespace Debugger;
|
||||
using namespace ProjectExplorer;
|
||||
using namespace Utils;
|
||||
|
||||
@@ -45,6 +48,7 @@ public:
|
||||
PySideBuildStepFactory buildStepFactory;
|
||||
PythonBuildConfigurationFactory buildConfigFactory;
|
||||
SimpleTargetRunnerFactory runWorkerFactory{{runConfigFactory.runConfigurationId()}};
|
||||
SimpleDebugRunnerFactory debugRunWorkerFactory{{runConfigFactory.runConfigurationId()}, {ProjectExplorer::Constants::DAP_PY_DEBUG_RUN_MODE}};
|
||||
PythonSettings settings;
|
||||
PythonWizardPageFactory pythonWizardPageFactory;
|
||||
};
|
||||
@@ -84,7 +88,7 @@ private:
|
||||
{
|
||||
// Add MIME overlay icons (these icons displayed at Project dock panel)
|
||||
const QString imageFile = Utils::creatorTheme()->imageFile(Theme::IconOverlayPro,
|
||||
::Constants::FILEOVERLAY_PY);
|
||||
ProjectExplorer::Constants::FILEOVERLAY_PY);
|
||||
FileIconProvider::registerIconOverlayForSuffix(imageFile, "py");
|
||||
|
||||
TaskHub::addCategory({PythonErrorTaskCategory,
|
||||
|
||||
Reference in New Issue
Block a user