aboutsummaryrefslogtreecommitdiffstats
path: root/examples/quick/threading/workerscript
diff options
context:
space:
mode:
Diffstat (limited to 'examples/quick/threading/workerscript')
-rw-r--r--examples/quick/threading/workerscript/Spinner.qml1
-rw-r--r--examples/quick/threading/workerscript/workerscript.qml2
2 files changed, 2 insertions, 1 deletions
diff --git a/examples/quick/threading/workerscript/Spinner.qml b/examples/quick/threading/workerscript/Spinner.qml
index 9c70090dba..a2257f8639 100644
--- a/examples/quick/threading/workerscript/Spinner.qml
+++ b/examples/quick/threading/workerscript/Spinner.qml
@@ -78,6 +78,7 @@ Rectangle {
clip: true
model: 64
delegate: Text {
+ required property int index
font.pixelSize: 18;
color: "white";
text: index;
diff --git a/examples/quick/threading/workerscript/workerscript.qml b/examples/quick/threading/workerscript/workerscript.qml
index 735cc8d1f1..eb8ad43d01 100644
--- a/examples/quick/threading/workerscript/workerscript.qml
+++ b/examples/quick/threading/workerscript/workerscript.qml
@@ -58,7 +58,7 @@ Rectangle {
id: myWorker
source: "workerscript.mjs"
- onMessage: {
+ onMessage: (messageObject) => {
if (messageObject.row == rowSpinner.value && messageObject.column == columnSpinner.value){ //Not an old result
if (messageObject.result == -1)
resultText.text = "Column must be <= Row";