diff --git a/src/plugins/debugger/debuggerplugin.cpp b/src/plugins/debugger/debuggerplugin.cpp index 7453e720da0..f33880d3fc4 100644 --- a/src/plugins/debugger/debuggerplugin.cpp +++ b/src/plugins/debugger/debuggerplugin.cpp @@ -709,12 +709,7 @@ public: DebuggerKitAspect debuggerKitAspect; CommonOptionsPage commonOptionsPage; - RunWorkerFactory debuggerWorkerFactory{ - RunWorkerFactory::make(), - {ProjectExplorer::Constants::DEBUG_RUN_MODE}, - {}, // All local run configs? - {PE::DESKTOP_DEVICE_TYPE, "DockerDeviceType"} - }; + DebuggerRunWorkerFactory debuggerWorkerFactory; // FIXME: Needed? // QString mainScript = runConfig->property("mainScript").toString(); diff --git a/src/plugins/debugger/debuggerruncontrol.cpp b/src/plugins/debugger/debuggerruncontrol.cpp index 62bb6b7edf3..13283b5416b 100644 --- a/src/plugins/debugger/debuggerruncontrol.cpp +++ b/src/plugins/debugger/debuggerruncontrol.cpp @@ -1073,4 +1073,14 @@ void DebugServerRunner::setAttachPid(ProcessHandle pid) m_pid = pid; } -} // namespace Debugger +// DebuggerRunWorkerFactory + +DebuggerRunWorkerFactory::DebuggerRunWorkerFactory() +{ + setProduct(); + addSupportedRunMode(ProjectExplorer::Constants::DEBUG_RUN_MODE); + addSupportedDeviceType(ProjectExplorer::Constants::DESKTOP_DEVICE_TYPE); + addSupportedDeviceType("DockerDeviceType"); +} + +} // Debugger diff --git a/src/plugins/debugger/debuggerruncontrol.h b/src/plugins/debugger/debuggerruncontrol.h index 6daca73a2c4..4c5198b4c3b 100644 --- a/src/plugins/debugger/debuggerruncontrol.h +++ b/src/plugins/debugger/debuggerruncontrol.h @@ -155,7 +155,13 @@ private: bool m_useMulti = true; }; +class DebuggerRunWorkerFactory final : public ProjectExplorer::RunWorkerFactory +{ +public: + DebuggerRunWorkerFactory(); +}; + extern DEBUGGER_EXPORT const char DebugServerRunnerWorkerId[]; extern DEBUGGER_EXPORT const char GdbServerPortGathererWorkerId[]; -} // namespace Debugger +} // Debugger