mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
QML UI: use action button for save in GPS preferences
For consistency Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
23b877a869
commit
da5be2249d
1 changed files with 10 additions and 28 deletions
|
@ -8,18 +8,17 @@ import org.subsurfacedivelog.mobile 1.0
|
||||||
|
|
||||||
MobileComponents.Page {
|
MobileComponents.Page {
|
||||||
|
|
||||||
/* this can be done by hitting the back key
|
mainAction: Action {
|
||||||
contextualActions: [
|
text: "Save"
|
||||||
Action {
|
iconName: "document-save"
|
||||||
text: "Close Preferences"
|
onTriggered: {
|
||||||
iconName: "dialog-cancel"
|
manager.distanceThreshold = distanceThreshold.text
|
||||||
onTriggered: {
|
manager.timeThreshold = timeThreshold.text
|
||||||
stackView.pop()
|
manager.savePreferences()
|
||||||
contextDrawer.close()
|
stackView.pop()
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
}
|
||||||
*/
|
|
||||||
GridLayout {
|
GridLayout {
|
||||||
|
|
||||||
signal accept
|
signal accept
|
||||||
|
@ -67,23 +66,6 @@ MobileComponents.Page {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
|
|
||||||
Item { width: MobileComponents.Units.gridUnit; height: width }
|
|
||||||
Item {
|
|
||||||
Layout.preferredHeight: saveButton.height
|
|
||||||
Layout.preferredWidth: saveButton.width
|
|
||||||
SubsurfaceButton {
|
|
||||||
id: saveButton
|
|
||||||
text: "Save"
|
|
||||||
anchors.centerIn: parent
|
|
||||||
onClicked: {
|
|
||||||
manager.distanceThreshold = distanceThreshold.text
|
|
||||||
manager.timeThreshold = timeThreshold.text
|
|
||||||
manager.savePreferences()
|
|
||||||
stackView.pop()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue