blob: 0867b861fa0e432733a235edc0810be71463a3dc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
// Copyright (C) 2016 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
import QtQuick 2.0
import test.PythonObject 1.0
Rectangle {
id: page
required property PythonObject python
function simpleFunction() {
python.called = "simpleFunction"
}
function oneArgFunction(x) {
python.called = "oneArgFunction"
python.arg1 = x
}
function twoArgFunction(x, y) {
python.called = "twoArgFunction"
python.arg1 = x
python.arg2 = y
}
function returnFunction() {
python.called = "returnFunction"
return 42
}
}
|