mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-28 13:10:19 +00:00
mobile-widgets/qml: move dive computers to general section.
move gridlayout divecomputers to TemplateSection general, without changing anything (apart from adding a visible: attribute and replacing the Rectangle used to draw a line at the bottom with a TemplateLine on top. Signed-off-by: jan Iversen <jan@casacondor.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3d239a7903
commit
ba7a8f68bc
1 changed files with 32 additions and 35 deletions
|
@ -98,6 +98,38 @@ Kirigami.ScrollablePage {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
TemplateLine {
|
||||||
|
visible: sectionGeneral.isExpanded
|
||||||
|
}
|
||||||
|
GridLayout {
|
||||||
|
id: divecomputers
|
||||||
|
visible: sectionGeneral.isExpanded
|
||||||
|
columns: 2
|
||||||
|
TemplateLabel {
|
||||||
|
text: qsTr("Dive computers")
|
||||||
|
font.pointSize: subsurfaceTheme.headingPointSize
|
||||||
|
font.weight: Font.Light
|
||||||
|
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||||
|
Layout.bottomMargin: Kirigami.Units.largeSpacing
|
||||||
|
Layout.columnSpan: 2
|
||||||
|
}
|
||||||
|
TemplateLabel {
|
||||||
|
text: qsTr("Forget remembered dive computers")
|
||||||
|
Layout.preferredWidth: gridWidth * 0.75
|
||||||
|
}
|
||||||
|
SsrfButton {
|
||||||
|
id: forgetDCButton
|
||||||
|
text: qsTr("Forget")
|
||||||
|
enabled: PrefDiveComputer.vendor1 !== ""
|
||||||
|
onClicked: {
|
||||||
|
PrefDiveComputer.vendor1 = PrefDiveComputer.product1 = PrefDiveComputer.device1 = ""
|
||||||
|
PrefDiveComputer.vendor2 = PrefDiveComputer.product2 = PrefDiveComputer.device2 = ""
|
||||||
|
PrefDiveComputer.vendor3 = PrefDiveComputer.product3 = PrefDiveComputer.device3 = ""
|
||||||
|
PrefDiveComputer.vendor4 = PrefDiveComputer.product4 = PrefDiveComputer.device4 = ""
|
||||||
|
PrefDiveComputer.vendor = PrefDiveComputer.product = PrefDiveComputer.device = ""
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -365,41 +397,6 @@ Kirigami.ScrollablePage {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
|
|
||||||
GridLayout {
|
|
||||||
id: divecomputers
|
|
||||||
columns: 2
|
|
||||||
TemplateLabel {
|
|
||||||
text: qsTr("Dive computers")
|
|
||||||
font.pointSize: subsurfaceTheme.headingPointSize
|
|
||||||
font.weight: Font.Light
|
|
||||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
|
||||||
Layout.bottomMargin: Kirigami.Units.largeSpacing
|
|
||||||
Layout.columnSpan: 2
|
|
||||||
}
|
|
||||||
TemplateLabel {
|
|
||||||
text: qsTr("Forget remembered dive computers")
|
|
||||||
Layout.preferredWidth: gridWidth * 0.75
|
|
||||||
}
|
|
||||||
SsrfButton {
|
|
||||||
id: forgetDCButton
|
|
||||||
text: qsTr("Forget")
|
|
||||||
enabled: PrefDiveComputer.vendor1 !== ""
|
|
||||||
onClicked: {
|
|
||||||
PrefDiveComputer.vendor1 = PrefDiveComputer.product1 = PrefDiveComputer.device1 = ""
|
|
||||||
PrefDiveComputer.vendor2 = PrefDiveComputer.product2 = PrefDiveComputer.device2 = ""
|
|
||||||
PrefDiveComputer.vendor3 = PrefDiveComputer.product3 = PrefDiveComputer.device3 = ""
|
|
||||||
PrefDiveComputer.vendor4 = PrefDiveComputer.product4 = PrefDiveComputer.device4 = ""
|
|
||||||
PrefDiveComputer.vendor = PrefDiveComputer.product = PrefDiveComputer.device = ""
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Rectangle {
|
|
||||||
color: subsurfaceTheme.darkerPrimaryColor
|
|
||||||
height: 1
|
|
||||||
opacity: 0.5
|
|
||||||
Layout.fillWidth: true
|
|
||||||
}
|
|
||||||
GridLayout {
|
GridLayout {
|
||||||
id: unit_system
|
id: unit_system
|
||||||
columns: 2
|
columns: 2
|
||||||
|
|
Loading…
Reference in a new issue