Skip to content

Commit

Permalink
Make geofencing digitizing prohibition a project-level setting via qf…
Browse files Browse the repository at this point in the history
…ieldsync
  • Loading branch information
nirvn committed Jul 4, 2024
1 parent 5ab32eb commit 9cf8bf0
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 37 deletions.
37 changes: 0 additions & 37 deletions src/qml/QFieldSettings.qml
Original file line number Diff line number Diff line change
Expand Up @@ -1335,43 +1335,6 @@ Page {
width: 1
}

Label {
text: qsTr("Prevent digitizing while geofencing is in alert mode")
font: Theme.defaultFont
color: Theme.mainTextColor
wrapMode: Text.WordWrap
Layout.fillWidth: true

MouseArea {
anchors.fill: parent
onClicked: geofencingPreventDigitizingDuringAlert.toggle()
}
}

QfSwitch {
id: geofencingPreventDigitizingDuringAlert
Layout.preferredWidth: implicitContentWidth
Layout.alignment: Qt.AlignTop
checked: positioningSettings.geofencingPreventDigitizingDuringAlert
onCheckedChanged: {
positioningSettings.geofencingPreventDigitizingDuringAlert = checked;
}
}

Label {
text: qsTr("When enabled, the digitizing of new features will be blocked if a project's geofencing is active and the current position triggers an alert.")
font: Theme.tipFont
color: Theme.secondaryTextColor

wrapMode: Text.WordWrap
Layout.fillWidth: true
}

Item {
// empty cell in grid layout
width: 1
}

Label {
text: qsTr("Antenna height compensation")
font: Theme.defaultFont
Expand Down
1 change: 1 addition & 0 deletions src/qml/qgismobileapp.qml
Original file line number Diff line number Diff line change
Expand Up @@ -3373,6 +3373,7 @@ ApplicationWindow {
}
layoutListInstantiator.model.reloadModel();
geofencer.applyProjectSettings(qgisProject);
positioningSettings.geofencingPreventDigitizingDuringAlert = iface.readProjectBoolEntry("qfieldsync", "/geofencingPreventDigitizing", false);
}

function onSetMapExtent(extent) {
Expand Down

0 comments on commit 9cf8bf0

Please sign in to comment.