aboutsummaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorAlexei Cazacov <alexei.cazacov@qt.io>2024-12-18 11:30:33 +0200
committerAlexei Cazacov <alexei.cazacov@qt.io>2025-01-24 09:19:13 +0200
commit44beb8080c44c1956d15c1df5de984614612fd68 (patch)
tree6c6e0f48185da28ce3c3c59426211cef48986641 /examples
parentc66101af52260891744f91d7f31b6277e8ed75e0 (diff)
Docs: Update the published QML code to reflect current best practices
This commit addresses the edit proposals mentioned in the QTBUG-131978. Task-number: QTBUG-131978 Pick-to: 6.9 6.8 Change-Id: Ib94379c6dc0778f5aee8e53c5f1015ad7b10779f Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'examples')
-rw-r--r--examples/quick/animation/behaviors/wigglytext.qml2
-rw-r--r--examples/quick/animation/easing/easing.qml2
-rw-r--r--examples/quick/customitems/painteditem/textballoons.qml4
3 files changed, 4 insertions, 4 deletions
diff --git a/examples/quick/animation/behaviors/wigglytext.qml b/examples/quick/animation/behaviors/wigglytext.qml
index 1b987f6391..f8918fd7d2 100644
--- a/examples/quick/animation/behaviors/wigglytext.qml
+++ b/examples/quick/animation/behaviors/wigglytext.qml
@@ -22,7 +22,7 @@ Rectangle {
}
}
- function append(text) {
+ function append(text: string) {
container.animated = false
const lastLetter = container.children[container.children.length - 1]
let newLetter = letterComponent.createObject(container)
diff --git a/examples/quick/animation/easing/easing.qml b/examples/quick/animation/easing/easing.qml
index 8b58bd5538..df95b8eacc 100644
--- a/examples/quick/animation/easing/easing.qml
+++ b/examples/quick/animation/easing/easing.qml
@@ -11,7 +11,7 @@ Rectangle {
id: window
width: 320; height: 480; color: "#232323"
- property var easingCurve: [ 0.2, 0.2, 0.13, 0.65, 0.2, 0.8,
+ property list<real> easingCurve: [ 0.2, 0.2, 0.13, 0.65, 0.2, 0.8,
0.624, 0.98, 0.93, 0.95, 1, 1 ]
ListModel {
diff --git a/examples/quick/customitems/painteditem/textballoons.qml b/examples/quick/customitems/painteditem/textballoons.qml
index 1ef491f061..0af5ca252f 100644
--- a/examples/quick/customitems/painteditem/textballoons.qml
+++ b/examples/quick/customitems/painteditem/textballoons.qml
@@ -25,9 +25,9 @@ Item {
anchors.bottomMargin: 2
anchors.top: parent.top
delegate: TextBalloon {
- anchors.right: index % 2 != 0 ? parent?.right : undefined
+ anchors.right: index % 2 !== 0 ? parent?.right : undefined
height: 60
- rightAligned: index % 2 != 0
+ rightAligned: index % 2 !== 0
width: balloonWidth
}
model: balloonModel