mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-30 11:10:23 +02:00
lcl: add TBitmap.ReleaseMaskHandle by analogy with TBitmap.ReleaseHandle
git-svn-id: trunk@13198 -
This commit is contained in:
parent
87c4e64232
commit
5c61bf6aaa
@ -1086,6 +1086,7 @@ type
|
||||
procedure FreeHandle; override;
|
||||
procedure FreeMaskHandle;
|
||||
function ReleaseHandle: HBITMAP;
|
||||
function ReleaseMaskHandle: HBITMAP;
|
||||
function IsEmpty: boolean;
|
||||
function GetPixelFormat: TPixelFormat;
|
||||
public
|
||||
@ -1198,6 +1199,7 @@ type
|
||||
procedure ReadStream(Stream: TStream; UseSize: boolean; Size: Longint); virtual;
|
||||
procedure WriteStream(Stream: TStream; WriteSize: Boolean); virtual;
|
||||
function ReleaseHandle: HBITMAP;
|
||||
function ReleaseMaskHandle: HBITMAP;
|
||||
function ReleasePalette: HPALETTE;
|
||||
class function GetFPReaderForFileExt(
|
||||
const FileExtension: string): TFPCustomImageReaderClass; override;
|
||||
|
@ -1096,6 +1096,12 @@ begin
|
||||
Result := FImage.ReleaseHandle;
|
||||
end;
|
||||
|
||||
function TBitmap.ReleaseMaskHandle: HBITMAP;
|
||||
begin
|
||||
FreeCanvasContext;
|
||||
Result := FImage.ReleaseMaskHandle;
|
||||
end;
|
||||
|
||||
function TBitmap.ReleasePalette: HPALETTE;
|
||||
begin
|
||||
// ToDo
|
||||
|
@ -81,6 +81,12 @@ begin
|
||||
FHandle:=0;
|
||||
end;
|
||||
|
||||
function TBitmapImage.ReleaseMaskHandle: HBITMAP;
|
||||
begin
|
||||
Result := FMaskHandle;
|
||||
FMaskHandle := 0;
|
||||
end;
|
||||
|
||||
function TBitmapImage.IsEmpty: boolean;
|
||||
begin
|
||||
Result := (FHandle = 0) and (FDIBHandle = 0)
|
||||
|
Loading…
Reference in New Issue
Block a user