mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-15 17:29:40 +02:00
patch from bug #19747: Masked property not set correctly when assigning TIcon to TBitmap
git-svn-id: trunk@32932 -
This commit is contained in:
parent
69140ad22a
commit
3577059604
@ -1615,7 +1615,6 @@ type
|
||||
function GetIndex(AFormat: TPixelFormat; AHeight, AWidth: Word): Integer;
|
||||
function GetBitmapHandle: HBITMAP; override;
|
||||
class function GetDefaultSize: TSize; virtual;
|
||||
function GetMasked: Boolean; override;
|
||||
function GetMaskHandle: HBITMAP; override;
|
||||
function GetPalette: HPALETTE; override;
|
||||
function GetPixelFormat: TPixelFormat; override;
|
||||
|
@ -499,6 +499,8 @@ begin
|
||||
inherited Create;
|
||||
FCurrent := -1;
|
||||
FRequestedSize := Size(0, 0);
|
||||
// per definition an icon is masked, but maybe we should make it settable for alpha images
|
||||
FMasked := True;
|
||||
end;
|
||||
|
||||
procedure TCustomIcon.Delete(Aindex: Integer);
|
||||
@ -556,12 +558,6 @@ begin
|
||||
Result := TSharedIcon(FSharedImage).GetIndex(AFormat, AHeight, AWidth);
|
||||
end;
|
||||
|
||||
function TCustomIcon.GetMasked: Boolean;
|
||||
begin
|
||||
// per definition an icon is masked, but maybe we should make it settable for alpha images
|
||||
Result := True;
|
||||
end;
|
||||
|
||||
function TCustomIcon.GetMaskHandle: HBITMAP;
|
||||
begin
|
||||
if FCurrent = -1
|
||||
|
Loading…
Reference in New Issue
Block a user