Details
-
Bug
-
Resolution: Cannot Reproduce
-
P2: Important
-
4.7.0
-
None
Description
import Qt 4.7 Item { width : 400 height : 400 VisualItemModel { id : slideModel Rectangle { width : ListView.view.width / 2 height : ListView.view.height / 2 color : "blue" } } ListView { anchors.fill : parent model : slideModel } }
main.qml:11: TypeError: Result of expression 'ListView.view' [null] is not an object.
If I take the rectangle into a custom item it works:
Item { width : 400 height : 400 VisualItemModel { id : slideModel Ext {} } ListView { anchors.fill : parent model : slideModel } }
Ext.qml:
import Qt 4.7 Rectangle { width : ListView.view.width / 2 height : ListView.view.height / 2 color : "blue" }