[lazarus] Order of destruction in TCustomListBox

Micha Nelissen micha at neli.hopto.org
Sat Dec 13 11:14:31 EST 2003


Mattias Gaertner wrote:
> On Fri, 12 Dec 2003 17:02:56 +0100  Vincent Snijders <vslist at zonnet.nl>
> wrote:
> 
>>As I am implementing the TCheckListBox items collection for win32, I
>>would like to access the listbox handle, while in the destructor of the
>>items collection. Unfortunately the window (+ items + item data stored
>>in it) are lost before the destructor for the items collection is
>>called. 
>>
> The Destroying; can accelerate the destruction and DestroyWnd will clean up.
> Maybe such things should be added to more controls.
> 
> I think, we should keep fItems like the VCL until after the "inherited
> Destroy;".

Do you know why the order is like it is in the VCL?

Micha.






More information about the Lazarus mailing list