It is already changing width with outer rectangle. Because the delegate's width property is already bound to the width of listArea
. But the problem is that the highlight
in contactView
isn't changing it's width.
This could be fixed by bounding the width property in the highlight
of contact view to be bound to the width of listArea
like the contactDelegate
which would make it something like this
highlight: Rectangle { color: "lightsteelblue"; radius: 5; width: listArea.width }
here is a like to the documentation about property binding http://qt-project.org/doc/qt-4.8/propertybinding.html