fix(dock): centralize tear-off logic and ensure transactional integrity

This commit is contained in:
2026-03-28 16:10:25 +09:00
parent 299bcf520c
commit 08e4d3311a
4 changed files with 67 additions and 26 deletions

View File

@@ -53,6 +53,16 @@ public partial class App : Application
}
}
/// <summary>
/// Creates, registers, and shows a new DockWindow for a torn-off tab.
/// </summary>
internal static void CreateAndShowDockWindow(object tabContent)
{
var newWindow = new Ghost.Editor.View.Windows.DockWindow(tabContent);
AddSecondaryWindow(newWindow);
newWindow.Activate();
}
internal IHost Host
{
get;