Compare commits

...

3 Commits

Author SHA1 Message Date
Dirk Hohndel
37f12453a5 Update Changelog
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-10-06 20:17:10 -07:00
Dirk Hohndel
a77ae75d6a mobile: show location service warning
Google play now requires that we show an explicit notification when turning
on background location. This is an attempt to fulfill that requirement - we
won't know if this is 'good enough' until we submit the app, though.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-10-06 20:16:16 -07:00
Dirk Hohndel
e1f2d49361 mobile: show text with location service icon
I don't recall why we removed that text, but this makes it much clearer
that the service is active.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-10-06 20:02:56 -07:00
2 changed files with 52 additions and 4 deletions

View File

@ -1,3 +1,4 @@
- mobile: add location service warning as required by Google Play
- desktop: allow adding dives to arbitrary trips - desktop: allow adding dives to arbitrary trips
- core: improve merging of cylinder pressures [#2884] - core: improve merging of cylinder pressures [#2884]
- desktop: respect page-up, page-down, home and end keys for selection change [#2957] - desktop: respect page-up, page-down, home and end keys for selection change [#2957]

View File

@ -423,6 +423,10 @@ if you have network connectivity and want to sync your data to cloud storage."),
onTriggered: { onTriggered: {
globalDrawer.close(); globalDrawer.close();
locationServiceEnabled = !locationServiceEnabled locationServiceEnabled = !locationServiceEnabled
if (locationServiceEnabled) {
locationWarning.open()
}
} }
} }
}, },
@ -600,11 +604,20 @@ if you have network connectivity and want to sync your data to cloud storage."),
*/ */
} }
] // end actions ] // end actions
Row {
spacing: Kirigami.Units.smallSpacing
Image { Image {
id: ls_logo
fillMode: Image.PreserveAspectFit fillMode: Image.PreserveAspectFit
source: "qrc:///icons/" + (subsurfaceTheme.currentTheme !== "" ? subsurfaceTheme.currentTheme : "Blue") + "_gps.svg" source: "qrc:///icons/" + (subsurfaceTheme.currentTheme !== "" ? subsurfaceTheme.currentTheme : "Blue") + "_gps.svg"
visible: locationServiceEnabled visible: locationServiceEnabled
} }
Text {
text: qsTr("Background location service active")
visible: locationServiceEnabled
anchors.verticalCenter: ls_logo.verticalCenter
}
}
} }
function setupUnits() { function setupUnits() {
@ -757,6 +770,40 @@ if you have network connectivity and want to sync your data to cloud storage."),
} }
} }
Kirigami.OverlaySheet {
id: locationWarning
ColumnLayout {
width: locationWarning.width - Kirigami.Units.gridUnit
spacing: Kirigami.Units.gridUnit
TemplateTitle {
Layout.alignment: Qt.AlignHCenter
title: qsTr("Location Service Enabled")
}
Text {
Layout.fillWidth: true
wrapMode: Text.WrapAtWordBoundaryOrAnywhere
text: qsTr("This service collects location data to enable you to track the GPS coordinates of your dives. " +
"This will attempt to continue to collect location data, even if the app is closed or your phone screen locked.")
}
Text {
Layout.fillWidth: true
wrapMode: Text.WrapAtWordBoundaryOrAnywhere
text: qsTr("The location data are not used in way, except when you apply the location data to the dives in your dive list on this device.")
}
Text {
Layout.fillWidth: true
wrapMode: Text.WrapAtWordBoundaryOrAnywhere
text: qsTr("By default, the location data are never transferred to the cloud or to any other service. However, in order to allow debugging " +
"of location data related issues, you can explicitly enable storing those location data in the cloud by enabling the corresponding option in the advanced settings.")
}
TemplateButton {
Layout.alignment: Qt.AlignHCenter
text: qsTr("Understood")
onClicked: { locationWarning.close() }
}
}
}
Label { Label {
id: textBlock id: textBlock
visible: !initialized visible: !initialized