feat: add on state logic

This commit is contained in:
loner
2025-11-04 02:28:36 +08:00
parent 5c19c8433e
commit e182fe2552
4 changed files with 247 additions and 37 deletions
+28
View File
@@ -847,6 +847,34 @@
"tooltip": {
"label": "Tooltip",
"description": "The tooltip to show when hovering over the button."
},
"on-state-icon": {
"label": "On State Icon",
"description": "The icon for the button when it's in the 'on' state."
},
"on-clicked": {
"label": "Left Click Command",
"description": "Command to execute when the button is left-clicked."
},
"on-right-clicked": {
"label": "Right Click Command",
"description": "Command to execute when the button is right-clicked."
},
"on-middle-clicked": {
"label": "Middle Click Command",
"description": "Command to execute when the button is middle-clicked."
},
"on-state-command": {
"label": "On State Check Command",
"description": "Command to execute to check if the button should be in the 'on' state. Returns 0 for on, non-zero for off."
},
"general-tooltip-text": {
"label": "General Tooltip Text",
"description": "General description for the button's tooltip."
},
"enable-on-state-logic": {
"label": "Enable On-State Logic",
"description": "Enable a second icon and 'hot' state based on a check command."
}
},
"dialog": {