forked from qt-creator/qt-creator
Introduce processImplHook
Call new hook from inside QtcProcess::start(). This hook calls new virtual method IDevice::createProcessInterface(). That's all what should be needed from device to setup properly device specific process. Make QtcProcess::createProcessInterface() private now. Change-Id: I2136698063bafc846ebc2d3db6cc11376902eff0 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -56,8 +56,6 @@ public:
|
||||
QtcProcess(QObject *parent = nullptr);
|
||||
~QtcProcess();
|
||||
|
||||
void setProcessInterface(ProcessInterface *interface);
|
||||
|
||||
// ProcessInterface related
|
||||
|
||||
void start() override;
|
||||
@@ -215,6 +213,8 @@ public:
|
||||
QString toStandaloneCommandLine() const;
|
||||
|
||||
private:
|
||||
void setProcessInterface(ProcessInterface *interface);
|
||||
|
||||
friend QTCREATOR_UTILS_EXPORT QDebug operator<<(QDebug str, const QtcProcess &r);
|
||||
|
||||
friend class Internal::QtcProcessPrivate;
|
||||
@@ -229,6 +229,8 @@ private:
|
||||
class DeviceProcessHooks
|
||||
{
|
||||
public:
|
||||
std::function<ProcessInterface *(const FilePath &)> processImplHook;
|
||||
// TODO: remove this hook
|
||||
std::function<void(QtcProcess &)> startProcessHook;
|
||||
std::function<Environment(const FilePath &)> systemEnvironmentForBinary;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user