diff options
author | Andrew den Exter <andrew.den-exter@nokia.com> | 2012-07-27 12:33:27 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-08-02 02:43:36 +0200 |
commit | f915ea135fe4bf74432ffa3e6041ea60d4268c67 (patch) | |
tree | eb10268a72d7e4494e7b02c215bc62d42fd82aa1 /tests/auto/quick/qquickvisualdatamodel/data/singleroleproperties-package.qml | |
parent | 8dabc28e4ea6fe7946ee7770ba39410c6d95bc1d (diff) |
Fix handling of changes to the root index of a VisualDataModel.
Store the root index as a QPersistentModelIndex so the index remains
valid as the model changes, and in the case the root index is
removed from the model invalidate the contents of the VisualDataModel
until a new root index or model is set.
Change-Id: I1cbc27f2068f99a02ff3d43373905dec7e35e900
Reviewed-by: Martin Jones <martin.jones@nokia.com>
Diffstat (limited to 'tests/auto/quick/qquickvisualdatamodel/data/singleroleproperties-package.qml')
-rw-r--r-- | tests/auto/quick/qquickvisualdatamodel/data/singleroleproperties-package.qml | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/auto/quick/qquickvisualdatamodel/data/singleroleproperties-package.qml b/tests/auto/quick/qquickvisualdatamodel/data/singleroleproperties-package.qml index 910df816f3..1af1b3858d 100644 --- a/tests/auto/quick/qquickvisualdatamodel/data/singleroleproperties-package.qml +++ b/tests/auto/quick/qquickvisualdatamodel/data/singleroleproperties-package.qml @@ -15,7 +15,9 @@ ListView { VisualDataGroup { id: selectedItems; objectName: "selectedItems"; name: "selected" } ] - model: SingleRoleModel {} + model: SingleRoleModel { + values: [ "one", "two", "three", "four" ] + } delegate: Package { id: delegate |