mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-18 20:39:14 +02:00
gtk: format code to determine check/radio state in DrawFrameControl for better readability
git-svn-id: trunk@23266 -
This commit is contained in:
parent
991f66b576
commit
1b22f11d7f
@ -2627,21 +2627,14 @@ var
|
|||||||
else
|
else
|
||||||
Shadow := GTK_SHADOW_OUT; //unchecked style
|
Shadow := GTK_SHADOW_OUT; //unchecked style
|
||||||
|
|
||||||
if (DFCS_PUSHED and uState)<>0 then begin
|
if (DFCS_PUSHED and uState)<>0 then
|
||||||
STATE := GTK_STATE_ACTIVE;//button pressed(GTK ignores disabled)
|
State := GTK_STATE_ACTIVE //button pressed(GTK ignores disabled)
|
||||||
end
|
else if (DFCS_INACTIVE and uState)<>0 then
|
||||||
else begin
|
State := GTK_STATE_INSENSITIVE //button disabled
|
||||||
if (DFCS_INACTIVE and uState)<>0 then begin
|
else if (DFCS_HOT and uState)<>0 then
|
||||||
State:=GTK_STATE_INSENSITIVE;//button disabled
|
State := GTK_STATE_PRELIGHT // button enabled, special (e.g. mouse over)
|
||||||
end else
|
else
|
||||||
if (DFCS_HOT and uState)<>0 then begin
|
State := GTK_STATE_NORMAL; // button enabled, normal
|
||||||
// button enabled, special (e.g. mouse over)
|
|
||||||
State:=GTK_STATE_PRELIGHT;
|
|
||||||
end else begin
|
|
||||||
// button enabled, normal
|
|
||||||
State:=GTK_STATE_NORMAL;
|
|
||||||
end;
|
|
||||||
end;
|
|
||||||
|
|
||||||
aDC:=TGtkDeviceContext(DC);
|
aDC:=TGtkDeviceContext(DC);
|
||||||
DCOrigin := aDC.Offset;
|
DCOrigin := aDC.Offset;
|
||||||
|
Loading…
Reference in New Issue
Block a user