LCL: fixed calling recursively ShowControl on TControl.Show

git-svn-id: trunk@46551 -
This commit is contained in:
mattias 2014-10-14 07:39:30 +00:00
parent ee30d04a07
commit 959a877e86
3 changed files with 5 additions and 5 deletions

View File

@ -916,7 +916,6 @@ procedure TCustomTabControl.ShowControl(APage: TControl);
var
i: LongInt;
begin
//inherited ShowControl(AControl);
{ Find a child control that matches the one passed in and display
the page that contains that control. This method is necessary
for compatibility with Delphi }
@ -926,6 +925,7 @@ begin
Exit;
end;
end;
inherited ShowControl(APage);
end;
{------------------------------------------------------------------------------

View File

@ -233,8 +233,7 @@ begin
if AControl = ActivePageComponent then exit;
i := FPageList.IndexOf(Pointer(aControl));
if i >= 0 then
PageIndex := i
else
inherited ShowControl(AControl);
PageIndex := i;
inherited ShowControl(AControl);
end;

View File

@ -8395,7 +8395,8 @@ end;
Params: AControl: Control to show
Returns: nothing
Asks the parent to show ourself.
Called by a child control (in TControl.Show), before setting Visible=true.
Asks to show the child control and recursively shows the parents.
------------------------------------------------------------------------------}
procedure TWinControl.ShowControl(AControl: TControl);
begin