Re: [Interest] binding two QML object within C++

2014-05-29 Thread Ian Monroe
On Thu, May 29, 2014 at 12:35 PM, Alex Montgomery wrote: > Hello, > > I'm trying to do something that seems very simple, but I can't find a > solution anywhere. If I have two QML items that I've created from components > in C++, how do I bind a property on one to follow a property on the other > o

Re: [Interest] binding two QML object within C++

2014-05-29 Thread Thiago Macieira
Em qui 29 maio 2014, às 12:35:11, Alex Montgomery escreveu: > // C++ code > QQmlComponent simpleFactory; > simpleFactory.loadUrl(QUrl("qrc:///Qml/Simple.qml")); > QQuickItem* item1 = qobject_cast(m_simpleFactory.create()); > QQuickItem* item2 = qobject_cast(m_simpleFactory.create()); > > // how do

[Interest] binding two QML object within C++

2014-05-29 Thread Alex Montgomery
Hello, I'm trying to do something that seems very simple, but I can't find a solution anywhere. If I have two QML items that I've created from components in C++, how do I bind a property on one to follow a property on the other one? Here's a simple example: // Simple.qml Rectangle { property b