Make Behaviors work correctly with value types.
authorGlenn Watson <glenn.watson@nokia.com>
Sun, 1 Jul 2012 23:10:49 +0000 (09:10 +1000)
committerQt by Nokia <qt-info@nokia.com>
Wed, 4 Jul 2012 01:31:04 +0000 (03:31 +0200)
commitf18b66ac6cfc734d217ec9d44876774f25e5d900
tree7d8dffc65886f87a88c76d1ec29adca00d23b167
parentac9b09d4299bae22f6aa4b5423092167761d1c8d
Make Behaviors work correctly with value types.

When a value type is referenced by sub-component a grouped
property is built. This code path did not handle behaviors being
declared on the entire value type. Add support for value interceptors
in this code path. Also issue an additional write to the value
type property before calling the interceptor on components
that are not being intercepted, so that the other
sub-components don't get stale values during write back.

Task-number: QTBUG-22625
Change-Id: I3365f422dfa1ab2e536e19575efcceceffb85e10
Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
src/qml/qml/qqmlcompiler.cpp
src/qml/qml/qqmlvmemetaobject.cpp
tests/auto/qml/qqmlvaluetypes/data/grouped_interceptors_component.qml [new file with mode: 0644]
tests/auto/qml/qqmlvaluetypes/data/grouped_interceptors_ignore.qml [new file with mode: 0644]
tests/auto/qml/qqmlvaluetypes/data/grouped_interceptors_value.qml [new file with mode: 0644]
tests/auto/qml/qqmlvaluetypes/testtypes.cpp
tests/auto/qml/qqmlvaluetypes/testtypes.h
tests/auto/qml/qqmlvaluetypes/tst_qqmlvaluetypes.cpp