aboutsummaryrefslogtreecommitdiffstats
path: root/tests/benchmarks/quickcontrols2/qmlbench/creation/delegates_swipedelegate.qml
diff options
context:
space:
mode:
authorMitch Curtis <mitch.curtis@qt.io>2021-07-28 11:21:25 +0200
committerMitch Curtis <mitch.curtis@qt.io>2021-07-28 11:21:25 +0200
commit16436239cd35ba7346b89a1f57d5b29dc786f4c6 (patch)
tree7e9011d0dfdda5ef9ccc302dae69ab3e5ba4b8cc /tests/benchmarks/quickcontrols2/qmlbench/creation/delegates_swipedelegate.qml
parent5a5b9c2344b961e984a2c860bb0c33022d641f32 (diff)
parent89d3486ad18d782a8141037a2bffb7992118cc78 (diff)
Merge qtquickcontrols2 into qtdeclarative
Diffstat (limited to 'tests/benchmarks/quickcontrols2/qmlbench/creation/delegates_swipedelegate.qml')
-rw-r--r--tests/benchmarks/quickcontrols2/qmlbench/creation/delegates_swipedelegate.qml15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/benchmarks/quickcontrols2/qmlbench/creation/delegates_swipedelegate.qml b/tests/benchmarks/quickcontrols2/qmlbench/creation/delegates_swipedelegate.qml
new file mode 100644
index 0000000000..5147bbb6d2
--- /dev/null
+++ b/tests/benchmarks/quickcontrols2/qmlbench/creation/delegates_swipedelegate.qml
@@ -0,0 +1,15 @@
+import QtQuick
+import QmlBench
+import QtQuick.Controls
+
+CreationBenchmark {
+ id: root
+ count: 20
+ staticCount: 1000
+ delegate: SwitchDelegate {
+ x: QmlBench.getRandom() * root.width - width
+ y: QmlBench.getRandom() * root.height - height
+ text: "SwipeDelegate"
+ down: index % 2
+ }
+}