diff options
Diffstat (limited to 'doc/src/snippets/declarative/script.js')
-rw-r--r-- | doc/src/snippets/declarative/script.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/doc/src/snippets/declarative/script.js b/doc/src/snippets/declarative/script.js index cd67311..f55dee3 100644 --- a/doc/src/snippets/declarative/script.js +++ b/doc/src/snippets/declarative/script.js @@ -1 +1,4 @@ -# Just here so that workerscript.qml succeeds. +WorkerScript.onMessage = function(message) { + // ... long-running operations and calculations are done here + WorkerScript.sendMessage({ 'reply': 'Mouse is at ' + message.x + ',' + message.y }) +} |