summaryrefslogtreecommitdiffstats
path: root/mobile-widgets
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2019-12-21 20:17:05 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2020-03-10 09:25:57 -0700
commitd55ea8f8750a7952d4e9e003bef57decc513d2d4 (patch)
tree0ea1fa5c472e184f172b6d9abc19d958c67653cc /mobile-widgets
parentc34b7857fcc03d2ede0d40063b49a36e1ad7d9dd (diff)
downloadsubsurface-d55ea8f8750a7952d4e9e003bef57decc513d2d4.tar.gz
mobile/divelist: remove showDiveIndex QML-function
The currently shown dive is now controlled by the core. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'mobile-widgets')
-rw-r--r--mobile-widgets/qml/DiveDetails.qml5
-rw-r--r--mobile-widgets/qml/DiveDetailsEdit.qml1
-rw-r--r--mobile-widgets/qml/DiveList.qml3
3 files changed, 0 insertions, 9 deletions
diff --git a/mobile-widgets/qml/DiveDetails.qml b/mobile-widgets/qml/DiveDetails.qml
index 86ca5ea63..da2b30cf7 100644
--- a/mobile-widgets/qml/DiveDetails.qml
+++ b/mobile-widgets/qml/DiveDetails.qml
@@ -229,11 +229,6 @@ Kirigami.Page {
}
}
- function showDiveIndex(id) {
- currentIndex = swipeModel.getIdxForId(id);
- diveDetailsListView.positionViewAtIndex(currentIndex, ListView.End);
- }
-
function endEditMode() {
// if we were adding a dive, we need to remove it
if (state === "add")
diff --git a/mobile-widgets/qml/DiveDetailsEdit.qml b/mobile-widgets/qml/DiveDetailsEdit.qml
index 9d10772e4..ceeaedaf6 100644
--- a/mobile-widgets/qml/DiveDetailsEdit.qml
+++ b/mobile-widgets/qml/DiveDetailsEdit.qml
@@ -137,7 +137,6 @@ Item {
diveDetailsListView.currentItem.modelData.visibility = detailsEdit.visibility
Qt.inputMethod.hide()
// now make sure we directly show the saved dive (this may be a new dive, or it may have moved)
- showDiveIndex(newIdx)
clearDetailsEdit()
}
diff --git a/mobile-widgets/qml/DiveList.qml b/mobile-widgets/qml/DiveList.qml
index 94289c6b7..a20a84f20 100644
--- a/mobile-widgets/qml/DiveList.qml
+++ b/mobile-widgets/qml/DiveList.qml
@@ -420,9 +420,6 @@ Kirigami.ScrollablePage {
if (diveListModel)
diveListModel.setActiveTrip(diveListView.currentItem.myData.tripId)
- // update the diveDetails page to also show that dive
- detailsWindow.showDiveIndex(idx)
-
// updating the index of the ListView triggers a non-linear scroll
// animation that can be very slow. the fix is to stop this animation
// by setting contentY to itself and then using positionViewAtIndex().