[Development] Property bindings in Qt 6
Simon Hausmann
Simon.Hausmann at qt.io
Sat Sep 28 08:40:33 CEST 2019
Yeah that’s one way that should work for sure.
Simon
> On 26. Sep 2019, at 20:54, Thiago Macieira <thiago.macieira at intel.com> wrote:
>
> On Thursday, 26 September 2019 08:38:40 PDT Mitch Curtis wrote:
>> https://code.qt.io/cgit/qt/qtquickcontrols2.git/tree/src/quicktemplates2/qqu
>> ickslider.cpp#n355
>>
>> In the end the solution was to use "dirty events" (i.e. derive from a
>> certain type, implement operator() and pass a pointer the property in its
>> constructor) as a way of reacting to the changes after they were made, but
>> this is not ideal.
>>
>> Will custom setters be possible?
>
> Can this be solved by the current solution for custom setters?
>
> void setFirstName(const QString &name);
> const QProperty<QString> &firstName() const;
> private:
> QProperty<QString> m_firstName;
>
> --
> Thiago Macieira - thiago.macieira (AT) intel.com
> Software Architect - Intel System Software Products
>
>
>
More information about the Development
mailing list