summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDavid Edmundson <davidedmundson@kde.org>2013-12-04 13:57:50 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-12-04 15:44:35 +0100
commit2a34659e22ce704101b7e8bc9b667044e801dc19 (patch)
treeff4ba6cae972c4c498067f6b899795ac24a95ed3 /src
parent9506149ecf6775dbc925d9c75439972189e5ef1a (diff)
downloadqtquickcontrols-2a34659e22ce704101b7e8bc9b667044e801dc19.tar.gz
qtquickcontrols-2a34659e22ce704101b7e8bc9b667044e801dc19.tar.bz2
qtquickcontrols-2a34659e22ce704101b7e8bc9b667044e801dc19.zip
Fix slider keyboard shortcuts in vertical orientation
Change-Id: Ib886a4bc9254d8e9c91ae52e927e651200b455a4 Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Diffstat (limited to 'src')
-rw-r--r--src/controls/Slider.qml6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/controls/Slider.qml b/src/controls/Slider.qml
index d87bb526..d31eb2c1 100644
--- a/src/controls/Slider.qml
+++ b/src/controls/Slider.qml
@@ -181,8 +181,10 @@ Control {
style: Qt.createComponent(Settings.style + "/SliderStyle.qml", slider)
- Keys.onRightPressed: value += (maximumValue - minimumValue)/10.0
- Keys.onLeftPressed: value -= (maximumValue - minimumValue)/10.0
+ Keys.onRightPressed: if (__horizontal) value += (maximumValue - minimumValue)/10.0
+ Keys.onLeftPressed: if (__horizontal) value -= (maximumValue - minimumValue)/10.0
+ Keys.onUpPressed: if (!__horizontal) value += (maximumValue - minimumValue)/10.0
+ Keys.onDownPressed: if (!__horizontal) value -= (maximumValue - minimumValue)/10.0
RangeModel {
id: range