From 7dd6ca01ca4e1171aa5629b406583b260d3d3097 Mon Sep 17 00:00:00 2001 From: Weng Xuetian Date: Fri, 11 Jan 2013 20:05:25 -0500 Subject: [PATCH] fix 'listItem.ListView.view' [null] is not an object warning attached property like obj.QmlType is consider as true in qml, should check full property obj.QmlType.property instead. --- declarativeimports/plasmacomponents/qml/ListItem.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/declarativeimports/plasmacomponents/qml/ListItem.qml b/declarativeimports/plasmacomponents/qml/ListItem.qml index 425b62301..509bfaf3c 100644 --- a/declarativeimports/plasmacomponents/qml/ListItem.qml +++ b/declarativeimports/plasmacomponents/qml/ListItem.qml @@ -89,7 +89,7 @@ Item { prefix: "normal" anchors.fill: parent - visible: listItem.ListView && listItem.ListView.view.highlight === null + visible: listItem.ListView.view ? listItem.ListView.view.highlight === null : false opacity: itemMouse.containsMouse && !itemMouse.pressed ? 0.5 : 1 Component.onCompleted: { prefix = (listItem.sectionDelegate ? "section" : (listItem.checked ? "pressed" : "normal"))