forked from qt-creator/qt-creator
Android: Remove some unused functions
Change-Id: I5c6549ed931b5132898abd6ce519560851838e65 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
This commit is contained in:
committed by
Assam Boudjelthia
parent
753c6812e2
commit
b6e4c9e133
@@ -428,19 +428,6 @@ FilePath AndroidConfig::adbToolPath() const
|
||||
return m_sdkLocation / "platform-tools/adb" QTC_HOST_EXE_SUFFIX;
|
||||
}
|
||||
|
||||
FilePath AndroidConfig::androidToolPath() const
|
||||
{
|
||||
if (HostOsInfo::isWindowsHost()) {
|
||||
// I want to switch from using android.bat to using an executable. All it really does is call
|
||||
// Java and I've made some progress on it. So if android.exe exists, return that instead.
|
||||
const FilePath path = m_sdkLocation / "tools/android" QTC_HOST_EXE_SUFFIX;
|
||||
if (path.exists())
|
||||
return path;
|
||||
return m_sdkLocation / "tools/android" ANDROID_BAT_SUFFIX;
|
||||
}
|
||||
return m_sdkLocation / "tools/android";
|
||||
}
|
||||
|
||||
FilePath AndroidConfig::emulatorToolPath() const
|
||||
{
|
||||
QString relativePath = "emulator/emulator";
|
||||
@@ -533,11 +520,6 @@ FilePath AndroidConfig::clangPathFromNdk(const Utils::FilePath &ndkLocation) con
|
||||
return path / HostOsInfo::withExecutableSuffix("bin/clang");
|
||||
}
|
||||
|
||||
FilePath AndroidConfig::clangPath(const BaseQtVersion *qtVersion) const
|
||||
{
|
||||
return clangPathFromNdk(ndkLocation(qtVersion));
|
||||
}
|
||||
|
||||
FilePath AndroidConfig::gdbPath(const ProjectExplorer::Abi &abi, const BaseQtVersion *qtVersion) const
|
||||
{
|
||||
return gdbPathFromNdk(abi, ndkLocation(qtVersion));
|
||||
@@ -558,11 +540,6 @@ FilePath AndroidConfig::gdbPathFromNdk(const Abi &abi, const FilePath &ndkLocati
|
||||
QString(QTC_HOST_EXE_SUFFIX)));
|
||||
}
|
||||
|
||||
FilePath AndroidConfig::makePath(const BaseQtVersion *qtVersion) const
|
||||
{
|
||||
return makePathFromNdk(ndkLocation(qtVersion));
|
||||
}
|
||||
|
||||
FilePath AndroidConfig::makePathFromNdk(const FilePath &ndkLocation) const
|
||||
{
|
||||
return ndkLocation.pathAppended(
|
||||
@@ -615,8 +592,6 @@ QVector<AndroidDeviceInfo> AndroidConfig::connectedDevices(const FilePath &adbTo
|
||||
foreach (const QString &device, adbDevs) {
|
||||
const QString serialNo = device.left(device.indexOf('\t')).trimmed();
|
||||
const QString deviceType = device.mid(device.indexOf('\t')).trimmed();
|
||||
if (isBootToQt(adbToolPath, serialNo))
|
||||
continue;
|
||||
AndroidDeviceInfo dev;
|
||||
dev.serialNumber = serialNo;
|
||||
dev.type = serialNo.startsWith(QLatin1String("emulator")) ? AndroidDeviceInfo::Emulator : AndroidDeviceInfo::Hardware;
|
||||
@@ -656,26 +631,6 @@ bool AndroidConfig::isConnected(const QString &serialNumber) const
|
||||
return false;
|
||||
}
|
||||
|
||||
bool AndroidConfig::isBootToQt(const QString &device) const
|
||||
{
|
||||
return isBootToQt(adbToolPath(), device);
|
||||
}
|
||||
|
||||
bool AndroidConfig::isBootToQt(const FilePath &adbToolPath, const QString &device)
|
||||
{
|
||||
// workaround for '????????????' serial numbers
|
||||
CommandLine cmd(adbToolPath, AndroidDeviceInfo::adbSelector(device));
|
||||
cmd.addArg("shell");
|
||||
cmd.addArg("ls -l /system/bin/appcontroller || ls -l /usr/bin/appcontroller && echo Boot2Qt");
|
||||
|
||||
SynchronousProcess adbProc;
|
||||
adbProc.setTimeoutS(10);
|
||||
SynchronousProcessResponse response = adbProc.runBlocking(cmd);
|
||||
return response.result == SynchronousProcessResponse::Finished
|
||||
&& response.allOutput().contains(QLatin1String("Boot2Qt"));
|
||||
}
|
||||
|
||||
|
||||
QString AndroidConfig::getDeviceProperty(const FilePath &adbToolPath, const QString &device, const QString &property)
|
||||
{
|
||||
// workaround for '????????????' serial numbers
|
||||
|
@@ -156,7 +156,6 @@ public:
|
||||
|
||||
static Utils::FilePath defaultSdkPath();
|
||||
Utils::FilePath adbToolPath() const;
|
||||
Utils::FilePath androidToolPath() const;
|
||||
Utils::FilePath emulatorToolPath() const;
|
||||
Utils::FilePath sdkManagerToolPath() const;
|
||||
Utils::FilePath avdManagerToolPath() const;
|
||||
@@ -164,12 +163,10 @@ public:
|
||||
|
||||
Utils::FilePath toolchainPath(const QtSupport::BaseQtVersion *qtVersion) const;
|
||||
Utils::FilePath toolchainPathFromNdk(const Utils::FilePath &ndkLocation) const;
|
||||
Utils::FilePath clangPath(const QtSupport::BaseQtVersion *qtVersion) const;
|
||||
Utils::FilePath clangPathFromNdk(const Utils::FilePath &ndkLocation) const;
|
||||
|
||||
Utils::FilePath gdbPath(const ProjectExplorer::Abi &abi, const QtSupport::BaseQtVersion *qtVersion) const;
|
||||
Utils::FilePath gdbPathFromNdk(const ProjectExplorer::Abi &abi, const Utils::FilePath &ndkLocation) const;
|
||||
Utils::FilePath makePath(const QtSupport::BaseQtVersion *qtVersion) const;
|
||||
Utils::FilePath makePathFromNdk(const Utils::FilePath &ndkLocation) const;
|
||||
|
||||
Utils::FilePath keytoolPath() const;
|
||||
@@ -212,8 +209,6 @@ private:
|
||||
static int getSDKVersion(const Utils::FilePath &adbToolPath, const QString &device);
|
||||
QStringList getAbis(const QString &device) const;
|
||||
static QStringList getAbis(const Utils::FilePath &adbToolPath, const QString &device);
|
||||
static bool isBootToQt(const Utils::FilePath &adbToolPath, const QString &device);
|
||||
bool isBootToQt(const QString &device) const;
|
||||
static QString getAvdName(const QString &serialnumber);
|
||||
|
||||
void parseDependenciesJson();
|
||||
|
Reference in New Issue
Block a user