[Qt-qml] Accessing QML objects from C++

John Vilburn john at ohanasoftware.com
Thu May 27 14:08:50 CEST 2010


> 
> If you set the objectName property (from QObject) on any of your objects in 
> QML you can then access that object using the findChild method on the root 
> object (also via QObject). This is the easiest way. In general though we 
> recommend that you not make your C++ layer use knowledge of the internals of 
> the QML files, so that you have more flexibility in rewriting the UI.
> 
Thank you. Very wise counsel. I will need to re-think my design.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt.nokia.com/pipermail/qt-qml/attachments/20100527/ae5c1d47/attachment.html 


More information about the Qt-qml mailing list