Designer: Name child controls only if owned by an added component. TPairSplitter may be the only one.

git-svn-id: trunk@64274 -
This commit is contained in:
juha 2020-12-25 17:26:39 +00:00
parent a28aa70a44
commit 4c2c4acb18

View File

@ -1644,7 +1644,7 @@ begin
for i:=0 to TWinControl(AComponent).ControlCount-1 do
begin
SubContrl:=TWinControl(AComponent).Controls[i];
if SubContrl.Name='' then
if (SubContrl.Owner<>AComponent) and (SubContrl.Name='') then
SubContrl.Name:=UniqueName(SubContrl.ClassName);
end;
GlobalDesignHook.PersistentAdded(AComponent,false);