mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-26 21:40:34 +02:00
Qt: fixed memleak in enumfontfamiliesex.
This commit is contained in:
parent
eb41784ad0
commit
c7bbb0b354
@ -1950,7 +1950,6 @@ begin
|
|||||||
if QtGetFontFamilies(FontList, lpLogFont^.lfPitchAndFamily,
|
if QtGetFontFamilies(FontList, lpLogFont^.lfPitchAndFamily,
|
||||||
lpLogFont^.lfFaceName, CharsetToQtCharSet(lpLogFont^.lfCharSet)) > 0 then
|
lpLogFont^.lfFaceName, CharsetToQtCharSet(lpLogFont^.lfCharSet)) > 0 then
|
||||||
begin
|
begin
|
||||||
StylesList := QStringList_create();
|
|
||||||
for i := 0 to FontList.Count - 1 do
|
for i := 0 to FontList.Count - 1 do
|
||||||
begin
|
begin
|
||||||
EnumLogFont.elfLogFont.lfFaceName := FontList[i];
|
EnumLogFont.elfLogFont.lfFaceName := FontList[i];
|
||||||
@ -1979,6 +1978,7 @@ begin
|
|||||||
finally
|
finally
|
||||||
FontList.free;
|
FontList.free;
|
||||||
QStringList_destroy(StylesList);
|
QStringList_destroy(StylesList);
|
||||||
|
QStringList_destroy(ScriptList);
|
||||||
CharSetList.Free;
|
CharSetList.Free;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user