From fe46c308ef3eb1be3c39eca680e9b01b6b749336 Mon Sep 17 00:00:00 2001 From: Andrew Lee Date: Mon, 1 Feb 2021 01:05:42 -0500 Subject: Added project files --- App.axaml.cs | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 App.axaml.cs (limited to 'App.axaml.cs') diff --git a/App.axaml.cs b/App.axaml.cs new file mode 100644 index 0000000..0ddebe2 --- /dev/null +++ b/App.axaml.cs @@ -0,0 +1,29 @@ +using Avalonia; +using Avalonia.Controls.ApplicationLifetimes; +using Avalonia.Markup.Xaml; +using Alee_Audio_Player.ViewModels; +using Alee_Audio_Player.Views; + +namespace Alee_Audio_Player +{ + public class App : Application + { + public override void Initialize() + { + AvaloniaXamlLoader.Load(this); + } + + public override void OnFrameworkInitializationCompleted() + { + if (ApplicationLifetime is IClassicDesktopStyleApplicationLifetime desktop) + { + desktop.MainWindow = new MainWindow + { + DataContext = new MainWindowViewModel(), + }; + } + + base.OnFrameworkInitializationCompleted(); + } + } +} \ No newline at end of file -- cgit v1.2.3