fix inverted sliders

This commit is contained in:
Marco Martin 2011-10-11 14:52:39 +02:00
parent 2ae8e31d77
commit 896499617d
2 changed files with 15 additions and 5 deletions

View File

@ -134,11 +134,10 @@ Item {
imagePath: "widgets/frame"
prefix: "sunken-active"
height: groove.height
width: range.position
anchors {
left: parent.left
verticalCenter: parent.verticalCenter
}
width: inverted ? groove.width - handle.x : fakeHandle.x
x: inverted ? handle.x : 0
anchors.verticalCenter: parent.verticalCenter
visible: range.position > 0 && slider.enabled
}

View File

@ -100,6 +100,17 @@ Column {
enabled: false
}
Text { text: "Inverted Horizontal Slider" }
PlasmaComponents.Slider {
id: invHorizontalSlider
width: 140
height: 20
inverted: true
animated: true
enabled: true
}
Text { text: "Vertical Slider" }
Row {