Skip to content

Commit

Permalink
fix: make the "Add Property" button non-toggleable
Browse files Browse the repository at this point in the history
Changing the text and meaning of the button unexpectedly for a
regular operation is not consistent with any other place, and
disregarded by the HIG.

The sheet can be closed by tapping outside of it, or throught
the close button in its titlebar, as usual elsewhere.
  • Loading branch information
ismailof authored and romangg committed Sep 23, 2024
1 parent c09682a commit bc5df0b
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions kcms/rules/ui/RulesEditor.qml
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,10 @@ KCM.ScrollViewKCM {

footer: RowLayout {
QQC2.Button {
text: checked ? i18n("Close") : i18n("Add Property...")
icon.name: checked ? "dialog-close" : "list-add"
checkable: true
checked: propertySheet.visible
onToggled: {
propertySheet.visible = checked;
text: i18n("Add Property...")
icon.name: "list-add"
onClicked: {
propertySheet.visible = true;
}
}
Item {
Expand Down

0 comments on commit bc5df0b

Please sign in to comment.