aboutsummaryrefslogtreecommitdiffstats
path: root/mobile-widgets/qml
diff options
context:
space:
mode:
Diffstat (limited to 'mobile-widgets/qml')
-rw-r--r--mobile-widgets/qml/DownloadFromDiveComputer.qml25
1 files changed, 19 insertions, 6 deletions
diff --git a/mobile-widgets/qml/DownloadFromDiveComputer.qml b/mobile-widgets/qml/DownloadFromDiveComputer.qml
index 8ef4520a2..5a732b73f 100644
--- a/mobile-widgets/qml/DownloadFromDiveComputer.qml
+++ b/mobile-widgets/qml/DownloadFromDiveComputer.qml
@@ -293,6 +293,24 @@ Kirigami.Page {
Layout.fillWidth: true
Layout.topMargin: Kirigami.Units.smallSpacing
spacing: Kirigami.Units.smallSpacing
+
+
+ function doDownload() {
+ var message = "DCDownloadThread started for " + manager.DC_vendor + " " + manager.DC_product + " on " + manager.DC_devName;
+ message += " downloading " + (manager.DC_forceDownload ? "all" : "only new" ) + " dives";
+ manager.appendTextToLog(message)
+ progressBar.visible = true
+ divesDownloaded = false // this allows the progressMessage to be displayed
+ importModel.startDownload()
+ }
+
+ Connections {
+ target: manager
+ onRestartDownloadSignal: {
+ buttonBar.doDownload()
+ }
+ }
+
TemplateButton {
id: download
text: qsTr("Download")
@@ -322,12 +340,7 @@ Kirigami.Page {
manager.DC_bluetoothMode = false;
manager.DC_devName = connectionString;
}
- var message = "DCDownloadThread started for " + manager.DC_vendor + " " + manager.DC_product + " on " + manager.DC_devName;
- message += " downloading " + (manager.DC_forceDownload ? "all" : "only new" ) + " dives";
- manager.appendTextToLog(message)
- progressBar.visible = true
- divesDownloaded = false // this allows the progressMessage to be displayed
- importModel.startDownload()
+ buttonBar.doDownload()
}
}
TemplateButton {