diff options
-rw-r--r-- | mobile-widgets/qml/DiveDetails.qml | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/mobile-widgets/qml/DiveDetails.qml b/mobile-widgets/qml/DiveDetails.qml index a4821ce62..6fed1355e 100644 --- a/mobile-widgets/qml/DiveDetails.qml +++ b/mobile-widgets/qml/DiveDetails.qml @@ -214,7 +214,15 @@ Kirigami.Page { } onCurrentItemChanged: { + // why do we do this? What consumes this? manager.selectedDiveTimestamp = currentItem.modelData.dive.timestamp + // make sure the core data structures reflect that this dive is selected + manager.selectDive(currentItem.modelData.dive.id) + // update the map to show the highlighted flag and center on it + if (rootItem.pageIndex(mapPage) !== -1) { + mapPage.reloadMap() + mapPage.centerOnDiveSite(currentItem.modelData.dive.dive_site) + } } function showDiveIndex(index) { |