diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2019-09-26 13:47:49 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2019-09-27 16:33:37 -0700 |
commit | eecca6aab0a1970c7474df7ac8408d810a5d0bbd (patch) | |
tree | 9c7fce46bb075dd013915ebf5ef6fcc2589303da /mobile-widgets | |
parent | 649ac1f83a7c2a5254363682c2c7cce9fd680ffe (diff) | |
download | subsurface-eecca6aab0a1970c7474df7ac8408d810a5d0bbd.tar.gz |
Mobile: replace model-reset by row-addition in DiveListModel::reload()
Owing to apparent QML breakage, a model-reset leads to the DiveDetail
page being reloaded for every dive in the list(!). Therefore, add
rows instead.
This leads to extremely subtle code, as it is now imperative that
the model has been properly cleared beforehand. Nevertheless, for
now we have to do this to fix a severe performance regression.
Fixes #2295
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'mobile-widgets')
-rw-r--r-- | mobile-widgets/qml/DownloadFromDiveComputer.qml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mobile-widgets/qml/DownloadFromDiveComputer.qml b/mobile-widgets/qml/DownloadFromDiveComputer.qml index 48fd816d8..51c96c044 100644 --- a/mobile-widgets/qml/DownloadFromDiveComputer.qml +++ b/mobile-widgets/qml/DownloadFromDiveComputer.qml @@ -391,7 +391,7 @@ Kirigami.Page { manager.appendTextToLog("Save downloaded dives that were selected") importModel.recordDives() manager.saveChangesLocal() - diveModel.reload() + diveModel.resetInternaData() pageStack.pop(); download.text = qsTr("Download") divesDownloaded = false |