Re: [Interest] Qml Loader initial property setter

2016-04-14 Thread Sina Dogru
It actually seems like doable. As documented section "QVariantList and QVariantMap to JavaScript Array and Object" on the "Data Type Conversion Between QML and C++ ", "passing a QVariantList

Re: [Interest] Qml Loader initial property setter

2016-04-13 Thread Jérôme Godbout
I agree, this would be difficult to know if this should create a binding or simply copy the current value. This is why I was proposing the function where we could go with either = or Qt.binding() to have full control on it. Nice to see this was there at some point, I wonder why they removed it or

Re: [Interest] Qml Loader initial property setter

2016-04-13 Thread Sina Dogru
> > It's sad that the imperative setSource() function can set those property > and the declarative way is not. > It would also be great but to make something a property instead of a function where it is much easier, then there should be a public and QMetaType known type.Thats why seems like hard

Re: [Interest] Qml Loader initial property setter

2016-04-03 Thread ekke
if you want to refer to a property as 'model.i' and there are situations where 'model' doesn't exist always, it's easy to avoid error messages: model? model.i : 42 this way you can set a default value while model is null (haven't tried this yet with Qt 5.6 but I'm doing it this way in BlackBerry

Re: [Interest] Qml Loader initial property setter

2016-04-01 Thread Jérôme Godbout
Yes, but the binding loaded object internal binding are printing error, since the object is created without the input, then the external binding are created. They will get eventually correct, but the console will be filled with error message and I try to avoid that at all cost. Here's a simple

Re: [Interest] Qml Loader initial property setter

2016-03-31 Thread Shantanu Tushar
Hi, Have you tried using the QML Binding Type? http://doc.qt.io/qt-5/qml-qtqml-binding.html On Thu, Mar 24, 2016 at 11:11 PM, Jérôme Godbout wrote: > Hi, > > I was wondering if I am the only one who found the initial property of a > source based Loader Item a bit annoying.

[Interest] Qml Loader initial property setter

2016-03-24 Thread Jérôme Godbout
Hi, I was wondering if I am the only one who found the initial property of a source based Loader Item a bit annoying. inline sourceComponent with Component {} declaration are well ok on the other hand. I'm explaining myself, when using a loader you have 2 choice to set the initial binding on