123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475 |
- import QtQuick
- import QtQuick.Templates as T
- import QtQuick.Controls.Material
- T.ScrollIndicator {
- id: control
- implicitWidth: Math.max(implicitBackgroundWidth + leftInset + rightInset,
- implicitContentWidth + leftPadding + rightPadding)
- implicitHeight: Math.max(implicitBackgroundHeight + topInset + bottomInset,
- implicitContentHeight + topPadding + bottomPadding)
- padding: 2
- contentItem: Rectangle {
- implicitWidth: 4
- implicitHeight: 4
- color: control.Material.scrollBarColor
- visible: control.size < 1.0
- opacity: 0.0
- states: State {
- name: "active"
- when: control.active
- PropertyChanges { target: control.contentItem; opacity: 0.75 }
- }
- transitions: [
- Transition {
- from: "active"
- SequentialAnimation {
- PauseAnimation { duration: 450 }
- NumberAnimation { target: control.contentItem; duration: 200; property: "opacity"; to: 0.0 }
- }
- }
- ]
- }
- }
|