forked from qt-creator/qt-creator
ProjectExplorer: Remove RunControl::worker<Type>()
It looks like the case where workers need talk to each other by only knowing the type of the 'partner' does not exist in practice anymore. With the now-common setup of a 'primary' worker that one can introduce the 'lesser' workers to each other directly. That's also conceptually more robust that picking a partner by type only only from some 'pool' (all the workers in a runcontrol), scales better (it e.g. is imaginable that a RunControl needs more than one PortGatherer in complex setups where more than one device is involved) saves a few cycles, and even removes the need for workers to be qobject_cast-able. Change-Id: Ib3d8c942c893d6c198d9813cce7df28ba3260ce8 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io> Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -125,7 +125,8 @@ class DEBUGGER_EXPORT GdbServerRunner : public ProjectExplorer::RunWorker
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit GdbServerRunner(ProjectExplorer::RunControl *runControl);
|
||||
explicit GdbServerRunner(ProjectExplorer::RunControl *runControl,
|
||||
GdbServerPortsGatherer *portsGatherer);
|
||||
~GdbServerRunner();
|
||||
|
||||
private:
|
||||
@@ -133,6 +134,7 @@ private:
|
||||
void stop() override;
|
||||
|
||||
ProjectExplorer::ApplicationLauncher m_gdbServer;
|
||||
GdbServerPortsGatherer *m_portsGatherer;
|
||||
};
|
||||
|
||||
extern DEBUGGER_EXPORT const char GdbServerRunnerWorkerId[];
|
||||
|
||||
Reference in New Issue
Block a user