feat: Implement Control Center custom button basic framework

This commit is contained in:
loner
2025-11-04 02:28:36 +08:00
parent 2c3d7bc101
commit 5c19c8433e
7 changed files with 268 additions and 11 deletions
+13 -2
View File
@@ -17,10 +17,18 @@ Singleton {
"PowerProfile": powerProfileComponent,
"ScreenRecorder": screenRecorderComponent,
"WiFi": wiFiComponent,
"WallpaperSelector": wallpaperSelectorComponent
"WallpaperSelector": wallpaperSelectorComponent,
"CustomButton": customButtonComponent
})
property var widgetMetadata: ({})
property var widgetMetadata: ({
"CustomButton": {
"allowUserSettings": true,
"icon": "heart",
"exec": "",
"tooltipText": "Custom Button"
}
})
// Component definitions - these are loaded once at startup
property Component bluetoothComponent: Component {
@@ -47,6 +55,9 @@ Singleton {
property Component wallpaperSelectorComponent: Component {
WallpaperSelector {}
}
property Component customButtonComponent: Component {
CustomButton {}
}
function init() {
Logger.i("ControlCenterWidgetRegistry", "Service started")