[Qt-qml] Using highlight with listview and multiple models
Pris Matic
prismatic.project at gmail.com
Sun Jul 24 22:33:38 CEST 2011
Hi all,
I have a ListView that I'm using with multiple models. The listview has a
highlight specified. The highlight works fine for the first model (the one
that is loaded when the ListView is loaded), but for subsequent models, the
highlight 'disappears' at the final count of the initial model.
So for example, if my first model has a count of 5 items I can move the
highlight up and down for all five items, and the list will scroll as
expected (highlightFollowsCurrentItem is true). If I change the model (say
to something that has 10 items), the highlight will only be visible for the
first 5 items, and will disappear for the sixth item and beyond. It will
reappear for the first 5 items. The view will still follow the current index
as expected for all items.
My highlight delegate is a simple rectangle, and printing out the ListView's
count property yields the correct number of items. Everything seems fine,
except for the fact that the highlight disappears!
I'd appreciate any help with this...
pris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt.nokia.com/pipermail/qt-qml/attachments/20110724/1bec602a/attachment.html
More information about the Qt-qml
mailing list