fix for speedbutton from Micha

git-svn-id: trunk@4682 -
This commit is contained in:
mattias 2003-09-27 09:49:30 +00:00
parent 452b7d6f5f
commit 13349a85c9
2 changed files with 11 additions and 5 deletions

View File

@ -233,7 +233,7 @@ type
function GetDrawFlags: integer; virtual; function GetDrawFlags: integer; virtual;
property MouseInControl : Boolean read FMouseInControl; property MouseInControl : Boolean read FMouseInControl;
public public
constructor Create(AOwner : TComponent); override; constructor Create(AOwner: TComponent); override;
destructor Destroy; override; destructor Destroy; override;
procedure Click; override; procedure Click; override;
published published
@ -307,6 +307,9 @@ end.
{ ============================================================================= { =============================================================================
$Log$ $Log$
Revision 1.51 2003/09/27 09:49:30 mattias
fix for speedbutton from Micha
Revision 1.50 2003/09/18 09:21:03 mattias Revision 1.50 2003/09/18 09:21:03 mattias
renamed LCLLinux to LCLIntf renamed LCLLinux to LCLIntf

View File

@ -244,7 +244,7 @@ function TSpeedButton.GetDrawFlags: integer;
begin begin
Result:=DFCS_BUTTONPUSH; Result:=DFCS_BUTTONPUSH;
if FState in [bsDown, bsExclusive] then inc(Result,DFCS_PUSHED); if FState in [bsDown, bsExclusive] then inc(Result,DFCS_PUSHED);
if FMouseInControl then inc(Result,DFCS_CHECKED); // if FMouseInControl then inc(Result,DFCS_CHECKED);
if not Enabled then inc(Result,DFCS_INACTIVE); if not Enabled then inc(Result,DFCS_INACTIVE);
if Flat and (not (csDesigning in ComponentState)) and if Flat and (not (csDesigning in ComponentState)) and
@ -539,9 +539,9 @@ begin
end; end;
end end
else begin else begin
{if not FMouseInControl then begin if not FMouseInControl then begin
UpdateTracking; UpdateTracking;
end;} end;
end; end;
end; end;
@ -563,7 +563,7 @@ begin
if FGroupIndex = 0 if FGroupIndex = 0
then begin then begin
FState := bsUp; FState := bsUp;
FMouseInControl := False; // FMouseInControl := False;
if not (FState in [bsExclusive, bsDown]) then if not (FState in [bsExclusive, bsDown]) then
Invalidate; Invalidate;
end end
@ -698,6 +698,9 @@ end;
{ ============================================================================= { =============================================================================
$Log$ $Log$
Revision 1.42 2003/09/27 09:49:30 mattias
fix for speedbutton from Micha
Revision 1.41 2003/06/23 09:42:09 mattias Revision 1.41 2003/06/23 09:42:09 mattias
fixes for debugging lazarus fixes for debugging lazarus