ACS: fixed freeing FILEFORMATS at program end (issue 13528)

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@789 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
vsnijders
2009-05-06 19:25:36 +00:00
parent e8364f826d
commit 99614b27af

View File

@ -97,8 +97,12 @@ type
so the user must only add your unit to the uses clausle to have support for
your fileformat.
}
{ tacsfileformatslist }
tacsfileformatslist = class (tlist)
public
destructor Destroy; override;
procedure Add(const Ext, Desc: String; AClass: TACSFormatClass);
function FindExt(ext : string;Typs : TACSFileCapTyps) : TACSFormatClass;
function FindFromFileName(const fileName : String;Typs : TACSFileCapTyps) : TACSFormatClass;
@ -565,6 +569,15 @@ end;
{ TACSFileFormatsList }
destructor tacsfileformatslist.Destroy;
var
i: integer;
begin
for i:= 0 to Count-1 do
TACSFileFormat(Items[i]).Free;
inherited Destroy;
end;
procedure TACSFileFormatsList.Add(const Ext, Desc: String;AClass: TACSFormatClass);
var
newRec : TACSFileFormat;