mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-22 16:48:29 +02:00
qt: if mask has been requested then create it anyway even empty (discussion of #0011902)
git-svn-id: trunk@16138 -
This commit is contained in:
parent
3dc4969f21
commit
428e708b0c
@ -351,10 +351,8 @@ begin
|
|||||||
Result := ABitmap <> 0;
|
Result := ABitmap <> 0;
|
||||||
|
|
||||||
if ASkipMask then Exit;
|
if ASkipMask then Exit;
|
||||||
if ARawImage.Mask = nil then Exit;
|
|
||||||
if ARawImage.MaskSize = 0 then Exit;
|
|
||||||
|
|
||||||
if ARawImage.MaskSize > 0 then
|
if (ARawImage.Mask <> nil) and (ARawImage.MaskSize > 0) then
|
||||||
begin
|
begin
|
||||||
NewData := GetMem(ARawImage.MaskSize);
|
NewData := GetMem(ARawImage.MaskSize);
|
||||||
Move(ARawImage.Mask^, NewData^, ARawImage.MaskSize);
|
Move(ARawImage.Mask^, NewData^, ARawImage.MaskSize);
|
||||||
|
@ -892,7 +892,10 @@ begin
|
|||||||
FDataOwner := ADataOwner;
|
FDataOwner := ADataOwner;
|
||||||
|
|
||||||
if FData = nil then
|
if FData = nil then
|
||||||
Handle := QImage_create(width, height, format)
|
begin
|
||||||
|
Handle := QImage_create(width, height, format);
|
||||||
|
QImage_fill(Handle, 0);
|
||||||
|
end
|
||||||
else
|
else
|
||||||
Handle := QImage_create(FData, width, height, format);
|
Handle := QImage_create(FData, width, height, format);
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user