win32 interface: fixed changing color of bitbtn (bug #9286)

git-svn-id: trunk@11814 -
This commit is contained in:
vincents 2007-08-14 11:47:38 +00:00
parent 9ba1b42342
commit 57286f6635

View File

@ -50,6 +50,7 @@ type
WithThemeSpace: Boolean); override;
class procedure SetBounds(const AWinControl: TWinControl;
const ALeft, ATop, AWidth, AHeight: integer); override;
class procedure SetColor(const AWinControl: TWinControl); override;
class procedure SetFont(const AWinControl: TWinControl; const AFont: TFont); override;
class procedure SetGlyph(const ABitBtn: TCustomBitBtn; const AValue: TBitmap); override;
class procedure SetLayout(const ABitBtn: TCustomBitBtn; const AValue: TButtonLayout); override;
@ -470,6 +471,13 @@ begin
DrawBitBtnImage(TCustomBitBtn(AWinControl), PChar(AWinControl.Caption));
end;
class procedure TWin32WSBitBtn.SetColor(const AWinControl: TWinControl);
begin
if not WSCheckHandleAllocated(AWinControl, 'SetColor') then Exit;
TWin32WSWinControl.SetColor(AWinControl);
DrawBitBtnImage(TCustomBitBtn(AWinControl), PChar(AWinControl.Caption));
end;
class procedure TWin32WSBitBtn.SetFont(const AWinControl: TWinControl;
const AFont: TFont);
begin