mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-08 12:39:18 +02:00
Cocoa: Fix the issue introduced @ 8ecc0ea
for example, the Icon cannot be displayed normally in VirtualTrees
This commit is contained in:
parent
1b9571bfcd
commit
db6ce9345e
@ -2193,18 +2193,11 @@ begin
|
|||||||
CGContextClipToMask(CGContext, ImgRect, MskImage);
|
CGContextClipToMask(CGContext, ImgRect, MskImage);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
if NOT ctx.isFlipped then begin
|
|
||||||
CGContextScaleCTM(CGContext, 1, -1);
|
|
||||||
CGContextTranslateCTM(CGContext, 0, -dcHeight);
|
|
||||||
Y:= dcHeight - (Height + Y);
|
|
||||||
end;
|
|
||||||
|
|
||||||
if NOT SrcDC.ctx.isFlipped then begin
|
if NOT SrcDC.ctx.isFlipped then begin
|
||||||
YSrc := Bmp.Height - (SrcHeight + YSrc);
|
YSrc := Bmp.Height - (SrcHeight + YSrc);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
Result := bmp.ImageRep.drawInRect_fromRect_operation_fraction_respectFlipped_hints(
|
Result := DrawImageRep(GetNSRect(X, Y, Width, Height),GetNSRect(XSrc, YSrc, SrcWidth, SrcHeight), bmp.ImageRep);
|
||||||
GetNSRect(X, Y, Width, Height), GetNSRect(XSrc, YSrc, SrcWidth, SrcHeight), NSCompositeSourceOver, 1.0, True, nil );
|
|
||||||
|
|
||||||
if Assigned(MskImage) then
|
if Assigned(MskImage) then
|
||||||
CGImageRelease(MskImage);
|
CGImageRelease(MskImage);
|
||||||
|
Loading…
Reference in New Issue
Block a user