[Lazarus] ListView duplicates list items?

Hans-Peter Diettrich DrDiettrich1 at aol.com
Sat Feb 12 20:07:11 CET 2011


I don't understand the idea behind the current ListView implementation :-(

Actually the ItemList is always created, and IMO also populated. This 
would make sense only when the widget is in OwnerData mode, otherwise 
the widget will duplicate all items.

It may make sense to manage the items in a local ItemList, but then the 
widget should always be in OwnerData mode. OTOH the local ItemList 
defeats the use of OwnerData, managed by the application outside the 
control.

In any case a redesign is suggested, that allows for true (application) 
OwnerData mode, where no items are stored in the control or widget, and 
a non-OwnerData mode with items stored in the control *or* in the widget 
(but not both).

DoDi





More information about the Lazarus mailing list