Commit 3d8cb4bf authored by LNJ's avatar LNJ 💬

roster: Open and close sheet on 'add contact' action

This also allows the user to close the sheet by pressing the 'add
contact' action again.
parent 35823097
......@@ -54,9 +54,11 @@ Kirigami.ScrollablePage {
mainAction: Kirigami.Action {
text: qsTr("Add new contact")
iconName: "contact-new"
enabled: !addContactSheet.sheetOpen
onTriggered: {
addContactSheet.open();
if (addContactSheet.sheetOpen)
addContactSheet.close()
else
addContactSheet.open()
}
}
......
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