forked from qt-creator/qt-creator
Android: Remove multiple code paths to run adb
Refactor the code to use adb from AndroidManager, do cleanup and improve logging Change-Id: I77b682d37c9328e6aa978eaf05b3b5c131907f09 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -46,9 +46,9 @@ class AndroidRunnerWorker : public QObject
|
||||
public:
|
||||
AndroidRunnerWorker(ProjectExplorer::RunWorker *runner, const QString &packageName);
|
||||
~AndroidRunnerWorker() override;
|
||||
bool adbShellAmNeedsQuotes();
|
||||
bool runAdb(const QStringList &args, int timeoutS = 10, const QByteArray &writeData = {});
|
||||
|
||||
bool uploadFile(const QString &from, const QString &to, const QString &flags = QString("+x"));
|
||||
bool runAdb(const QStringList &args, QString *stdOut = nullptr, const QByteArray &writeData = {});
|
||||
void adbKill(qint64 pid);
|
||||
QStringList selector() const;
|
||||
void forceStop();
|
||||
@@ -73,6 +73,7 @@ signals:
|
||||
|
||||
protected:
|
||||
void asyncStartHelper();
|
||||
bool startDebuggerServer(QString packageDir, QString *errorStr = nullptr);
|
||||
|
||||
enum class JDBState {
|
||||
Idle,
|
||||
@@ -88,7 +89,6 @@ protected:
|
||||
QString m_intentName;
|
||||
QStringList m_beforeStartAdbCommands;
|
||||
QStringList m_afterFinishAdbCommands;
|
||||
QString m_adb;
|
||||
QStringList m_amStartExtraArgs;
|
||||
qint64 m_processPID = -1;
|
||||
std::unique_ptr<QProcess, Deleter> m_adbLogcatProcess;
|
||||
@@ -101,8 +101,6 @@ protected:
|
||||
QmlDebug::QmlDebugServicesPreset m_qmlDebugServices;
|
||||
Utils::Port m_localGdbServerPort; // Local end of forwarded debug socket.
|
||||
QUrl m_qmlServer;
|
||||
QByteArray m_lastRunAdbRawOutput;
|
||||
QString m_lastRunAdbError;
|
||||
JDBState m_jdbState = JDBState::Idle;
|
||||
Utils::Port m_localJdbServerPort;
|
||||
std::unique_ptr<QProcess, Deleter> m_gdbServerProcess;
|
||||
|
||||
Reference in New Issue
Block a user