mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-01-28 15:32:50 -05:00
feat: Implement Color Picker
This commit is contained in:
@@ -21,7 +21,9 @@ PanelWindow {
|
||||
|
||||
property var modelData
|
||||
property var notepadVariants: null
|
||||
|
||||
|
||||
signal colorPickerRequested()
|
||||
|
||||
function getNotepadInstanceForScreen() {
|
||||
if (!notepadVariants || !notepadVariants.instances) return null
|
||||
|
||||
@@ -370,7 +372,8 @@ PanelWindow {
|
||||
"network_speed_monitor": networkComponent,
|
||||
"keyboard_layout_name": keyboardLayoutNameComponent,
|
||||
"vpn": vpnComponent,
|
||||
"notepadButton": notepadButtonComponent
|
||||
"notepadButton": notepadButtonComponent,
|
||||
"colorPicker": colorPickerComponent
|
||||
})
|
||||
|
||||
function getWidgetComponent(widgetId) {
|
||||
@@ -999,9 +1002,24 @@ PanelWindow {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Component {
|
||||
id: colorPickerComponent
|
||||
|
||||
ColorPicker {
|
||||
widgetHeight: root.widgetHeight
|
||||
barHeight: root.effectiveBarHeight
|
||||
section: topBarContent.getWidgetSection(parent) || "right"
|
||||
parentScreen: root.screen
|
||||
onColorPickerRequested: {
|
||||
root.colorPickerRequested()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user