diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2018-12-23 12:46:25 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2019-01-09 20:58:04 -0800 |
commit | f542dc4030dda5dac1da1cc928f7a40a50919c4d (patch) | |
tree | eb7f77bc9701c3180082da7f0435b9d467c565e7 /core/downloadfromdcthread.h | |
parent | 7e33369dc8b27b20385ab055b662e06bbf369784 (diff) | |
download | subsurface-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 'core/downloadfromdcthread.h')
-rw-r--r-- | core/downloadfromdcthread.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/downloadfromdcthread.h b/core/downloadfromdcthread.h index b380a88a1..426a807d9 100644 --- a/core/downloadfromdcthread.h +++ b/core/downloadfromdcthread.h @@ -61,6 +61,7 @@ private: class DownloadThread : public QThread { Q_OBJECT Q_PROPERTY(dive_table_t *table READ table CONSTANT) + Q_PROPERTY(trip_table_t *trips READ trips CONSTANT) public: DownloadThread(); @@ -68,6 +69,7 @@ public: DCDeviceData *data(); struct dive_table *table(); + struct trip_table *trips(); QString error; private: |