diff options
Diffstat (limited to 'widgets/StyledScrollBar.qml')
| -rw-r--r-- | widgets/StyledScrollBar.qml | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/widgets/StyledScrollBar.qml b/widgets/StyledScrollBar.qml index 889a1c3..b341173 100644 --- a/widgets/StyledScrollBar.qml +++ b/widgets/StyledScrollBar.qml @@ -6,11 +6,25 @@ ScrollBar { id: root contentItem: StyledRect { + opacity: 0 radius: Appearance.rounding.full - color: Qt.alpha(Appearance.colours.m3secondary, 0.5) + color: Qt.alpha(Appearance.colours.m3secondary, 0.6) } background: StyledRect { implicitWidth: 10 + opacity: 0 + radius: Appearance.rounding.full + color: Qt.alpha(Appearance.colours.m3surfaceContainerLow, 0.4) + + MouseArea { + anchors.fill: parent + onWheel: event => { + if (event.angleDelta.y > 0) + root.decrease(); + else if (event.angleDelta.y < 0) + root.increase(); + } + } } } |