2019-12-19 22:46:16 +11:00
|
|
|
// SPDX-License-Identifier: LGPL-3.0-or-later
|
|
|
|
|
2019-07-21 05:06:38 +10:00
|
|
|
import QtQuick 2.12
|
|
|
|
import QtQuick.Controls 2.12
|
|
|
|
|
|
|
|
Flickable {
|
2020-07-23 03:57:32 +10:00
|
|
|
id: flickable
|
2020-07-14 19:35:53 +10:00
|
|
|
maximumFlickVelocity: window.settings.kineticScrollingMaxSpeed
|
2020-07-14 19:46:48 +10:00
|
|
|
flickDeceleration: window.settings.kineticScrollingDeceleration
|
2020-07-14 19:35:53 +10:00
|
|
|
|
2020-06-20 02:03:04 +10:00
|
|
|
ScrollBar.vertical: HScrollBar {
|
2020-05-19 00:53:26 +10:00
|
|
|
visible: parent.interactive
|
2020-07-19 17:02:14 +10:00
|
|
|
z: 999
|
2020-08-19 23:36:52 +10:00
|
|
|
flickableMoving: flickable.moving
|
2020-05-16 09:32:44 +10:00
|
|
|
}
|
2020-07-23 03:57:32 +10:00
|
|
|
|
|
|
|
Component.onCompleted: {
|
|
|
|
kineticScrollingDisabler = Qt.createComponent(
|
|
|
|
"HKineticScrollingDisabler.qml"
|
2020-08-21 18:58:03 +10:00
|
|
|
).createObject(flickable, {flickable})
|
|
|
|
|
|
|
|
kineticScrollingDisabler.width = Qt.binding(() =>
|
|
|
|
kineticScrollingDisabler.enabled ? flickable.width : 0
|
|
|
|
)
|
|
|
|
kineticScrollingDisabler.height = Qt.binding(() =>
|
|
|
|
kineticScrollingDisabler.enabled ? flickable.height : 0
|
|
|
|
)
|
2020-07-23 03:57:32 +10:00
|
|
|
}
|
|
|
|
|
|
|
|
property var kineticScrollingDisabler
|
2019-07-21 05:06:38 +10:00
|
|
|
}
|