Hi Lazarus team,

The implementation of the OnSelectItem event of TListView doesn't appear to me to be correct.

With MultiSelect false, selecting a new Item on the list generates, as expected, two events: the unselect of the previous Item, and the select of the new one. But they're generated in the reverse order. i.e. first the selection of the new one, then the unselect of the old one.

This requires extra code in the application to verify if there's still an item selected or not: just handling the events one by one doesn't let you tell apart an unselect caused by other reasons (such as the selected item being deleted, or a programmatical unselection), from an unselect generated by a new select.

Is this a feature required to be bug-compatible with Delphi, or a bug of LCL of its own?

Giuliano


--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to