mirror of
https://github.com/Quill-OS/quill.git
synced 2024-10-31 21:33:22 -07:00
Tiny fixes in OTA updater
This commit is contained in:
parent
fe88cc43e9
commit
c328761bc5
2 changed files with 7 additions and 1 deletions
|
@ -29,6 +29,7 @@ otaManager::otaManager(QWidget *parent) :
|
|||
}
|
||||
unsigned long currentEpoch = QDateTime::currentSecsSinceEpoch();
|
||||
string_writeconfig("/external_root/opt/storage/update/last_sync", std::to_string(currentEpoch));
|
||||
QFile::remove("/run/can_ota_update");
|
||||
otaManager::close();
|
||||
}
|
||||
} );
|
||||
|
|
|
@ -903,7 +903,12 @@ void settings::on_globalReadingSettingsCheckBox_toggled(bool checked)
|
|||
void settings::on_checkOtaUpdateBtn_clicked()
|
||||
{
|
||||
log("'Check for OTA update' button clicked", className);
|
||||
launchOtaUpdater();
|
||||
if(testPing(true) == 0 or global::deviceID == "emu\n") {
|
||||
launchOtaUpdater();
|
||||
}
|
||||
else {
|
||||
emit showToast("Wi-Fi connection error");
|
||||
}
|
||||
}
|
||||
|
||||
void settings::openUpdateDialog() {
|
||||
|
|
Loading…
Reference in a new issue