summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/downloadfromdivecomputer.cpp
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2018-12-23 12:46:25 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2019-01-09 20:58:04 -0800
commitf542dc4030dda5dac1da1cc928f7a40a50919c4d (patch)
treeeb7f77bc9701c3180082da7f0435b9d467c565e7 /desktop-widgets/downloadfromdivecomputer.cpp
parent7e33369dc8b27b20385ab055b662e06bbf369784 (diff)
downloadsubsurface-f542dc4030dda5dac1da1cc928f7a40a50919c4d.tar.gz
Import: add trip_table argument to DiveImportedModel::repopulate()
In the future we want to download trips into a distinct trip-table instead of the global trip-table to allow for undo of import. Therefore add a trip_table argument to DiveImportedModel::repopulate() and a trip_table member to DiveImportedModel. To correctly set these, add a DownloadThread::trips() function, which currently simply returns the global trip table. Finally, make "struct trip_table *" a Q_METATYPE, so that the corresponding arguments can be passed from QML. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'desktop-widgets/downloadfromdivecomputer.cpp')
-rw-r--r--desktop-widgets/downloadfromdivecomputer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/desktop-widgets/downloadfromdivecomputer.cpp b/desktop-widgets/downloadfromdivecomputer.cpp
index 4221f5bf4..4e4c6a43c 100644
--- a/desktop-widgets/downloadfromdivecomputer.cpp
+++ b/desktop-widgets/downloadfromdivecomputer.cpp
@@ -490,7 +490,7 @@ void DownloadFromDCWidget::onDownloadThreadFinished()
}
ui.downloadCancelRetryButton->setText(tr("Retry download"));
ui.downloadCancelRetryButton->setEnabled(true);
- diveImportedModel->repopulate(thread.table());
+ diveImportedModel->repopulate(thread.table(), thread.trips());
}
void DownloadFromDCWidget::on_cancel_clicked()