fix(docking): address code quality issues in Docking system

This commit is contained in:
2026-03-28 22:43:44 +09:00
parent d367cff79f
commit e6d0529ef1
3 changed files with 7 additions and 8 deletions

View File

@@ -59,6 +59,11 @@ public class DockingLayout : Control
throw new InvalidOperationException("Panel is already owned by another DockingLayout");
}
if (newPanel.Owner != null)
{
newPanel.Owner.RemoveChild(newPanel);
}
newPanel.Root = layout;
}
}