Files
LlamaCasty/Controls/OverlayHost.xaml.cs
gramps 544208e002 refactor: extract OverlayHost (settings/bug/feature/about dialogs) — Phase 2, Commit 18
OverlayHost.xaml(.cs) takes the window-root overlay dialog grid (settings/
bug/feature/about panels); BackToAbout_Click moved in via inherited DataContext.
WebViewHostPanel + ToastArea stay as thin window-root stubs so the WebView2 ctor
init and NotificationService InArea('ToastArea') name lookups are untouched.
This completes Phase 2: MainWindow.xaml is now a 123-line shell.

Zero behavior change; build 0 warnings; 246 pass, only the 2 known failures.
Docs: ViewModels/index.md Phase 2 tracker updated in same commit.
2026-08-30 21:07:49 -07:00

23 lines
455 B
C#

using System.Windows;
using System.Windows.Controls;
using ytLive.ViewModels;
namespace ytLive.Controls;
public partial class OverlayHost : UserControl
{
public OverlayHost()
{
InitializeComponent();
}
private void BackToAbout_Click(object sender, RoutedEventArgs e)
{
if (DataContext is MainViewModel vm)
{
vm.IsLicensesOpen = false;
vm.IsLicenseEntryOpen = false;
}
}
}