[Qt-qml] JavaScript QML object properties
ext-ivailo.iliev at nokia.com
ext-ivailo.iliev at nokia.com
Mon Nov 22 10:08:30 CET 2010
Hi,
I want to play with QML object from within JavaScript. Everything is ok until you try to change property of QML object that is not explicitly set in the QML file. Then you have error:
example
Rectangle {
id: test
}
and then in the JS file you have test.visibile = false
So you have error that visible is not accessible.
BUT if you put:
Rectangle {
id:test
visible:true
}
then you can change visible to false from the JS
So my question is: is it required to set all properties once with QML so you can modify them later with JS or it's a problem temporary and will change. Or maybe there is something wrong in my environment - maybe I'm using old version or something else in the QML file causes this problem?
Best Regards,
Ivo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt.nokia.com/pipermail/qt-qml/attachments/20101122/6c1b3a00/attachment.html
More information about the Qt-qml
mailing list