diff options
author | Olivier Goffart <olivier.goffart@nokia.com> | 2010-07-28 09:12:15 (GMT) |
---|---|---|
committer | Olivier Goffart <olivier.goffart@nokia.com> | 2010-07-28 09:13:48 (GMT) |
commit | aa84b4412bf039045392bc0a033086656fd2c290 (patch) | |
tree | 8abd2e3a10ebe1894c74abf1135c1c0e644d36d5 /tests/auto/declarative/qdeclarativescriptdebugging/data | |
parent | 613ab517f46085580e81684cd5072f8c90fe84d5 (diff) | |
download | Qt-aa84b4412bf039045392bc0a033086656fd2c290.zip Qt-aa84b4412bf039045392bc0a033086656fd2c290.tar.gz Qt-aa84b4412bf039045392bc0a033086656fd2c290.tar.bz2 |
Add test for getting a backtrace in QML
Diffstat (limited to 'tests/auto/declarative/qdeclarativescriptdebugging/data')
-rw-r--r-- | tests/auto/declarative/qdeclarativescriptdebugging/data/backtrace1.js | 11 | ||||
-rw-r--r-- | tests/auto/declarative/qdeclarativescriptdebugging/data/backtrace1.qml | 27 |
2 files changed, 38 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativescriptdebugging/data/backtrace1.js b/tests/auto/declarative/qdeclarativescriptdebugging/data/backtrace1.js new file mode 100644 index 0000000..8decbf0 --- /dev/null +++ b/tests/auto/declarative/qdeclarativescriptdebugging/data/backtrace1.js @@ -0,0 +1,11 @@ + +function function2InScript(a) +{ + mainRectangle.foo = a; +} + + +function functionInScript(a , b) +{ + function2InScript(a + b); +} diff --git a/tests/auto/declarative/qdeclarativescriptdebugging/data/backtrace1.qml b/tests/auto/declarative/qdeclarativescriptdebugging/data/backtrace1.qml new file mode 100644 index 0000000..ad627ef --- /dev/null +++ b/tests/auto/declarative/qdeclarativescriptdebugging/data/backtrace1.qml @@ -0,0 +1,27 @@ +import Qt 4.7 +import Qt.test 1.0 +import "backtrace1.js" as Script + +Rectangle { + id: mainRectangle + + property string foo: "Default"; + width: 200 + height: 200 + + + MyTestObject { + + function append(a, b) { + return a + " " + b; + } + + + id: testObject; + someProperty: append("Hello", mainRectangle.foo) + + onSignaled: { + Script.functionInScript(value , "b"); + } + } +} |