Commit f76aafb7 authored by Martin Kacej's avatar Martin Kacej

Kirigami actions changed to footer buttons

parent 76933862
......@@ -63,27 +63,48 @@ Kirigami.ScrollablePage{
}
}
actions {
left: Kirigami.Action {
iconName: "dialog-ok"
text: i18n("Save")
enabled: enabledSaving
onTriggered: {
save()
applicationWindow().pageStack.pop()
footer: Item {
height: Kirigami.Units.gridUnit * 4
RowLayout {
anchors.horizontalCenter: parent.horizontalCenter
spacing: Kirigami.Units.gridUnit
Controls.Button {
enabled: enabledSaving
RowLayout {
anchors.centerIn: parent
Kirigami.Icon {
width: Kirigami.Units.iconSizes.smallMedium
height: width
source: "document-save"
}
Text {
text: i18n("Save")
}
}
onPressed: {
save()
applicationWindow().pageStack.pop()
}
}
}
right: Kirigami.Action {
iconName: "dialog-cancel"
text: i18n("Cancel")
onTriggered: {
applicationWindow().pageStack.pop()
Controls.Button {
RowLayout {
anchors.centerIn: parent
Kirigami.Icon {
width: Kirigami.Units.iconSizes.smallMedium
height: width
source: "dialog-cancel"
}
Text {
text: i18n("Cancel")
}
}
onPressed: {
applicationWindow().pageStack.pop()
}
}
}
}
function save() {
connection = editorIpSection.ipmap
connection["id"] = ssidField.text
......
......@@ -102,22 +102,44 @@ Kirigami.ScrollablePage{
id: detailsIP
}
}
actions {
left: Kirigami.Action {
iconName: "document-save"
text: i18n("Save")
enabled: enabledSave
onTriggered: {
save()
applicationWindow().pageStack.pop()
footer: Item {
height: Kirigami.Units.gridUnit * 4
RowLayout {
anchors.horizontalCenter: parent.horizontalCenter
spacing: Kirigami.Units.gridUnit
Controls.Button {
enabled: enabledSaving
RowLayout {
anchors.centerIn: parent
Kirigami.Icon {
width: Kirigami.Units.iconSizes.smallMedium
height: width
source: "document-save"
}
Text {
text: i18n("Save")
}
}
onPressed: {
save()
applicationWindow().pageStack.pop()
}
}
}
right: Kirigami.Action {
iconName: "dialog-cancel"
text: i18n("Cancel")
onTriggered: {
applicationWindow().pageStack.pop()
Controls.Button {
RowLayout {
anchors.centerIn: parent
Kirigami.Icon {
width: Kirigami.Units.iconSizes.smallMedium
height: width
source: "dialog-cancel"
}
Text {
text: i18n("Cancel")
}
}
onPressed: {
applicationWindow().pageStack.pop()
}
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment