ide: fix memory leak in imagelist editor

git-svn-id: trunk@12558 -
This commit is contained in:
paul 2007-10-23 02:47:38 +00:00
parent 3e3e217a58
commit 3be134f57d
2 changed files with 2 additions and 1 deletions

View File

@ -321,6 +321,7 @@ begin
ImageList.Insert(TreeView.Selected.ImageIndex, T, nil);
finally
ImageList.EndUpdate;
T.Free;
end;
TreeView.Invalidate;

View File

@ -127,7 +127,7 @@ class procedure TWin32WSCustomImageList.AddData(AListHandle: TLCLIntfHandle; ACo
DataCount := AWidth * AHeight;
DataSize := DataCount * SizeOf(AData^);
while ACOunt > 0 do
while ACount > 0 do
begin
System.Move(AData^, BitsPtr^, DataSize);
if AReplaceIndex = -1