1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2025-12-05 21:15:38 -05:00

Improve performance of slider

This commit is contained in:
bbedward
2025-07-12 12:06:33 -04:00
parent ba5217f2f1
commit 095606f6e9
2 changed files with 11 additions and 0 deletions

View File

@@ -205,6 +205,10 @@ ScrollView {
onSliderValueChanged: (newValue) => {
let transparencyValue = newValue / 100.0
displayTab.topBarTransparency = transparencyValue
}
onSliderDragFinished: (finalValue) => {
let transparencyValue = finalValue / 100.0
Prefs.setTopBarTransparency(transparencyValue)
}
}

View File

@@ -14,6 +14,7 @@ Item {
property bool showValue: true
signal sliderValueChanged(int newValue)
signal sliderDragFinished(int finalValue)
height: 80
@@ -133,6 +134,12 @@ Item {
slider.sliderValueChanged(newValue)
}
}
onReleased: {
if (slider.enabled) {
slider.sliderDragFinished(slider.value)
}
}
}
}