diff options
Diffstat (limited to 'tests/auto/declarative/qmlecmascript/data/dynamicCreation.qml')
-rw-r--r-- | tests/auto/declarative/qmlecmascript/data/dynamicCreation.qml | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/auto/declarative/qmlecmascript/data/dynamicCreation.qml b/tests/auto/declarative/qmlecmascript/data/dynamicCreation.qml new file mode 100644 index 0000000..f3eb75f --- /dev/null +++ b/tests/auto/declarative/qmlecmascript/data/dynamicCreation.qml @@ -0,0 +1,16 @@ +import Qt.test 1.0 + +MyQmlObject{ + id: obj + objectName: "obj" + function createOne() + { + obj.objectProperty = createQmlObject('import Qt.test 1.0; MyQmlObject{objectName:"emptyObject"}', obj); + } + + function createTwo() + { + var component = createComponent('dynamicCreation.helper.qml'); + obj.objectProperty = component.createObject(); + } +} |