mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-20 13:19:21 +02:00
LCL: High-DPI ImageList: add TCustomImageList.RegisterResolutions method.
git-svn-id: branches/HiDPIImageList@57041 -
This commit is contained in:
parent
4d88950a76
commit
9091957623
@ -315,8 +315,8 @@ type
|
|||||||
procedure RegisterChanges(Value: TChangeLink);
|
procedure RegisterChanges(Value: TChangeLink);
|
||||||
procedure StretchDraw(Canvas: TCanvas; Index: Integer; ARect: TRect; Enabled: Boolean = True);
|
procedure StretchDraw(Canvas: TCanvas; Index: Integer; ARect: TRect; Enabled: Boolean = True);
|
||||||
procedure UnRegisterChanges(Value: TChangeLink);
|
procedure UnRegisterChanges(Value: TChangeLink);
|
||||||
function Resolutions: TCustomImageListResolutionEnumerator;
|
|
||||||
function ResolutionsDesc: TCustomImageListResolutionEnumerator;
|
procedure RegisterResolutions(const AResolutionWidths: array of Integer);
|
||||||
public
|
public
|
||||||
property AllocBy: Integer read FAllocBy write FAllocBy default 4;
|
property AllocBy: Integer read FAllocBy write FAllocBy default 4;
|
||||||
property BlendColor: TColor read FBlendColor write FBlendColor default clNone;
|
property BlendColor: TColor read FBlendColor write FBlendColor default clNone;
|
||||||
@ -334,6 +334,8 @@ type
|
|||||||
property ReferenceForImagePPI[AImageWidth, APPI: Integer]: TWSCustomImageListReference read GetReferenceForImagePPI;
|
property ReferenceForImagePPI[AImageWidth, APPI: Integer]: TWSCustomImageListReference read GetReferenceForImagePPI;
|
||||||
property Resolution[AImageWidth: Integer]: TCustomImageListResolution read GetResolution;
|
property Resolution[AImageWidth: Integer]: TCustomImageListResolution read GetResolution;
|
||||||
property ResolutionForImagePPI[AImageWidth, APPI: Integer]: TCustomImageListResolution read GetResolutionForImagePPI;
|
property ResolutionForImagePPI[AImageWidth, APPI: Integer]: TCustomImageListResolution read GetResolutionForImagePPI;
|
||||||
|
function Resolutions: TCustomImageListResolutionEnumerator;
|
||||||
|
function ResolutionsDesc: TCustomImageListResolutionEnumerator;
|
||||||
property ShareImages: Boolean read FShareImages write SetShareImages default False;
|
property ShareImages: Boolean read FShareImages write SetShareImages default False;
|
||||||
property ImageType: TImageType read FImageType write FImageType default itImage;
|
property ImageType: TImageType read FImageType write FImageType default itImage;
|
||||||
property OnGetWidthForImagePPI: TCustomImageListGetWidthForImagePPI read FOnGetWidthForImagePPI write FOnGetWidthForImagePPI;
|
property OnGetWidthForImagePPI: TCustomImageListGetWidthForImagePPI read FOnGetWidthForImagePPI write FOnGetWidthForImagePPI;
|
||||||
|
@ -2008,6 +2008,15 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TCustomImageList.RegisterResolutions(
|
||||||
|
const AResolutionWidths: array of Integer);
|
||||||
|
var
|
||||||
|
R: Integer;
|
||||||
|
begin
|
||||||
|
for R in AResolutionWidths do
|
||||||
|
GetResolution(R);
|
||||||
|
end;
|
||||||
|
|
||||||
{------------------------------------------------------------------------------
|
{------------------------------------------------------------------------------
|
||||||
Method: TCustomImageList.Replace
|
Method: TCustomImageList.Replace
|
||||||
Params: Index: the index of the replaceded image
|
Params: Index: the index of the replaceded image
|
||||||
|
Loading…
Reference in New Issue
Block a user