lcl: add csNoDesignVisible to the HiddenRadioButton of TRadioGroup

git-svn-id: trunk@18458 -
This commit is contained in:
paul 2009-01-27 04:18:58 +00:00
parent acab2e4958
commit 685e4613f7
3 changed files with 7 additions and 7 deletions

View File

@ -192,7 +192,7 @@ type
csQuadClicks, // control understands mouse quad clicks
csFixedWidth,
csFixedHeight, // control cannot change it height (for example combobox)
csNoDesignVisible,
csNoDesignVisible, // control is invisible in the designer
csReplicatable,
csNoStdEvents,
csDisplayDragImage, // display images from dragimagelist during drag operation over control

View File

@ -696,7 +696,7 @@ type
FColumns: integer;
FCreatingWnd: boolean;
FHiddenButton: TRadioButton;
fIgnoreClicks: boolean;
FIgnoreClicks: boolean;
FItemIndex: integer;
FItems: TStrings;
FLastClickedItemIndex: integer;

View File

@ -170,7 +170,7 @@ begin
begin
Name := 'HiddenRadioButton';
Visible := False;
ControlStyle := ControlStyle + [csNoDesignSelectable];
ControlStyle := ControlStyle + [csNoDesignSelectable, csNoDesignVisible];
end;
end;
@ -351,8 +351,8 @@ begin
// Therefore there is a hidden button
OldItemIndex:=FItemIndex;
FItemIndex:=Value;
OldIgnoreClicks:=fIgnoreClicks;
fIgnoreClicks:=true;
OldIgnoreClicks:=FIgnoreClicks;
FIgnoreClicks:=true;
try
if (FItemIndex <> -1) then
TRadioButton(FButtonList[FItemIndex]).Checked := true
@ -365,7 +365,7 @@ begin
end else
FHiddenButton.Checked:=false;
finally
fIgnoreClicks:=OldIgnoreClicks;
FIgnoreClicks:=OldIgnoreClicks;
end;
// this has automatically unset the old button. But they do not recognize
// it. Update the states.
@ -442,7 +442,7 @@ end;
------------------------------------------------------------------------------}
procedure TCustomRadioGroup.Clicked(Sender : TObject);
Begin
if fIgnoreClicks then exit;
if FIgnoreClicks then exit;
CheckItemIndexChanged;
end;