We have a class:
T_FBPageCanvas = class
private
FCanvas:TCanvas;
FItem :T_FBItem;
FOwner :T_FBForm;
public
constructor Create(AOwner:T_FBForm);
function PaintItem(ASTR_ItemType:string):boolean;
function SetItemProperty:boolean;virtual;
end;
We have to create the FCanvas and other objects (delphi does not do this for us).
The question is, when we Free T_PageCanvas, are we freeing the "owned" objects as well (is delphi doing this for us) or do we have to do it. If we have to do it, is it appropriate for us to override the TObject.Destroy and handle it there?
Brian
"There are 2 kinds of people in the world, those that divide people into two groups and those that don't. I belong to the second group." - tag line I stole
T_FBPageCanvas = class
private
FCanvas:TCanvas;
FItem :T_FBItem;
FOwner :T_FBForm;
public
constructor Create(AOwner:T_FBForm);
function PaintItem(ASTR_ItemType:string):boolean;
function SetItemProperty:boolean;virtual;
end;
We have to create the FCanvas and other objects (delphi does not do this for us).
The question is, when we Free T_PageCanvas, are we freeing the "owned" objects as well (is delphi doing this for us) or do we have to do it. If we have to do it, is it appropriate for us to override the TObject.Destroy and handle it there?
Brian
"There are 2 kinds of people in the world, those that divide people into two groups and those that don't. I belong to the second group." - tag line I stole