1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2025-12-11 07:52:50 -05:00

ddc use raw values not percent

This commit is contained in:
bbedward
2025-11-05 09:23:14 -05:00
parent ce6f3afb39
commit d834124a71
3 changed files with 33 additions and 6 deletions

View File

@@ -150,8 +150,16 @@ Row {
if (!targetDevice) return 1
return (targetDevice.class === "backlight" || targetDevice.class === "ddc") ? 1 : 0
}
maximum: 100
maximum: {
if (!targetDevice) return 100
return targetDevice.displayMax || 100
}
value: targetBrightness
showValue: true
unit: {
if (!targetDevice) return "%"
return targetDevice.class === "ddc" ? "" : "%"
}
onSliderValueChanged: function (newValue) {
if (DisplayService.brightnessAvailable && targetDeviceName) {
DisplayService.setBrightness(newValue, targetDeviceName, true)