aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMitch Curtis <mitch.curtis@qt.io>2020-01-27 10:58:50 +0100
committerMitch Curtis <mitch.curtis@qt.io>2020-01-28 11:25:18 +0100
commitc5c945006244b6bf5189f1949a009f70ebd51d7a (patch)
tree7ecf5e74bccd544ab00d4a823e9a2c061eae07b6
parent20b9437d54b16abfdd7528868dea2a6c6de0c349 (diff)
Doc: fix RangeSlider errors
When the RangeSlider was copied into another file as a child item, it would produce errors about first and second being undefined. Change-Id: I0ecc9f6830509183a1b2b35e3faed5f06e78a0ef Fixes: QTBUG-80970 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
-rw-r--r--src/imports/controls/doc/snippets/qtquickcontrols2-rangeslider-custom.qml8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/imports/controls/doc/snippets/qtquickcontrols2-rangeslider-custom.qml b/src/imports/controls/doc/snippets/qtquickcontrols2-rangeslider-custom.qml
index 1c5db214..b8510ddd 100644
--- a/src/imports/controls/doc/snippets/qtquickcontrols2-rangeslider-custom.qml
+++ b/src/imports/controls/doc/snippets/qtquickcontrols2-rangeslider-custom.qml
@@ -54,22 +54,22 @@ RangeSlider {
}
first.handle: Rectangle {
- x: control.leftPadding + first.visualPosition * (control.availableWidth - width)
+ x: control.leftPadding + control.first.visualPosition * (control.availableWidth - width)
y: control.topPadding + control.availableHeight / 2 - height / 2
implicitWidth: 26
implicitHeight: 26
radius: 13
- color: first.pressed ? "#f0f0f0" : "#f6f6f6"
+ color: control.first.pressed ? "#f0f0f0" : "#f6f6f6"
border.color: "#bdbebf"
}
second.handle: Rectangle {
- x: control.leftPadding + second.visualPosition * (control.availableWidth - width)
+ x: control.leftPadding + control.second.visualPosition * (control.availableWidth - width)
y: control.topPadding + control.availableHeight / 2 - height / 2
implicitWidth: 26
implicitHeight: 26
radius: 13
- color: second.pressed ? "#f0f0f0" : "#f6f6f6"
+ color: control.second.pressed ? "#f0f0f0" : "#f6f6f6"
border.color: "#bdbebf"
}
}