Hide scrollbar in NListView if not necessary

This commit is contained in:
notiant
2025-11-16 11:05:25 +01:00
committed by GitHub
parent 098e7f5645
commit ef1b7cfd89
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -411,7 +411,7 @@ SmartPanel {
anchors.fill: parent
anchors.margins: Style.marginS
model: root.tabsModel
spacing: Style.marginXXS
spacing: Style.marginXS
currentIndex: root.currentTabIndex
verticalPolicy: ScrollBar.AsNeeded
+2 -2
View File
@@ -131,7 +131,7 @@ Item {
implicitHeight: 100
radius: root.handleRadius
color: parent.pressed ? root.handlePressedColor : parent.hovered ? root.handleHoverColor : root.handleColor
opacity: parent.policy === ScrollBar.AlwaysOn || parent.active ? 1.0 : 0.0
opacity: parent.policy === ScrollBar.AlwaysOn ? 1.0 : root.verticalScrollBarActive ? (parent.active ? 1.0 : 0.0) : 0.0
Behavior on opacity {
NumberAnimation {
@@ -150,7 +150,7 @@ Item {
implicitWidth: root.handleWidth
implicitHeight: 100
color: root.trackColor
opacity: parent.policy === ScrollBar.AlwaysOn || parent.active ? 0.3 : 0.0
opacity: parent.policy === ScrollBar.AlwaysOn ? 0.3 : root.verticalScrollBarActive ? (parent.active ? 0.3 : 0.0) : 0.0
radius: root.handleRadius / 2
Behavior on opacity {