Completed - downloading Installer (APK)

This commit is contained in:
NissimHadar 2019-01-25 14:34:11 -08:00
parent b95cc149aa
commit 57d3cec2f9
4 changed files with 13 additions and 4 deletions

View file

@ -113,7 +113,8 @@ void Nitpick::setup() {
_ui.folderLineEdit,
_ui.downloadAPKPushbutton,
_ui.runLatestOnMobileCheckBox,
_ui.urlOnMobileLineEdit
_ui.urlOnMobileLineEdit,
_ui.statusLabelOnMobile
);
}

View file

@ -25,6 +25,7 @@ TestRunnerMobile::TestRunnerMobile(
QPushButton* downloadAPKPushbutton,
QCheckBox* runLatest,
QLineEdit* url,
QLabel* statusLabel,
QObject* parent
) : QObject(parent)
@ -37,6 +38,7 @@ TestRunnerMobile::TestRunnerMobile(
_downloadAPKPushbutton = downloadAPKPushbutton;
_runLatest = runLatest;
_url = url;
_statusLabel = statusLabel;
folderLineEdit->setText("/sdcard/DCIM/TEST");
}
@ -124,6 +126,11 @@ void TestRunnerMobile::downloadComplete() {
_installerFilename = INSTALLER_FILENAME_LATEST;
// Replace the `exe` extension with `apk`
_installerFilename = _installerFilename.replace(_installerFilename.length() - 3, 3, "apk");
_buildInformation.url = _buildInformation.url.replace(_buildInformation.url.length() - 3, 3, "apk");
urls << _buildInformation.url;
filenames << _installerFilename;
} else {
@ -135,7 +142,7 @@ void TestRunnerMobile::downloadComplete() {
_statusLabel->setText("Downloading installer");
//// nitpick->downloadFiles(urls, _workingFolder, filenames, (void*)this);
nitpick->downloadFiles(urls, _workingFolder, filenames, (void*)this);
// `downloadComplete` will run again after download has completed

View file

@ -29,6 +29,7 @@ public:
QPushButton* downloadAPKPushbutton,
QCheckBox* runLatest,
QLineEdit* url,
QLabel* statusLabel,
QObject* parent = 0
);

View file

@ -630,8 +630,8 @@
<rect>
<x>10</x>
<y>350</y>
<width>441</width>
<height>31</height>
<width>440</width>
<height>30</height>
</rect>
</property>
</widget>