diff --git a/AIDevGallery/ProjectGenerator/Template/App.xaml.cs b/AIDevGallery/ProjectGenerator/Template/App.xaml.cs index 4c78b38..c2ad9bb 100644 --- a/AIDevGallery/ProjectGenerator/Template/App.xaml.cs +++ b/AIDevGallery/ProjectGenerator/Template/App.xaml.cs @@ -19,32 +19,31 @@ // To learn more about WinUI, the WinUI project structure, // and more about our project templates, see: http://aka.ms/winui-project-info. -namespace $safeprojectname$ +namespace $safeprojectname$; + +/// +/// Provides application-specific behavior to supplement the default Application class. +/// +public partial class App : Application { /// - /// Provides application-specific behavior to supplement the default Application class. + /// Initializes the singleton application object. This is the first line of authored code + /// executed, and as such is the logical equivalent of main() or WinMain(). /// - public partial class App : Application + public App() { - /// - /// Initializes the singleton application object. This is the first line of authored code - /// executed, and as such is the logical equivalent of main() or WinMain(). - /// - public App() - { - this.InitializeComponent(); - } - - /// - /// Invoked when the application is launched. - /// - /// Details about the launch request and process. - protected override void OnLaunched(Microsoft.UI.Xaml.LaunchActivatedEventArgs args) - { - Window = new MainWindow(); - Window.Activate(); - } + this.InitializeComponent(); + } - internal static MainWindow? Window { get; private set; } + /// + /// Invoked when the application is launched. + /// + /// Details about the launch request and process. + protected override void OnLaunched(Microsoft.UI.Xaml.LaunchActivatedEventArgs args) + { + Window = new MainWindow(); + Window.Activate(); } -} + + internal static MainWindow? Window { get; private set; } +} \ No newline at end of file diff --git a/AIDevGallery/ProjectGenerator/Template/MainWindow.xaml.cs b/AIDevGallery/ProjectGenerator/Template/MainWindow.xaml.cs index ba7e49a..52f4cf0 100644 --- a/AIDevGallery/ProjectGenerator/Template/MainWindow.xaml.cs +++ b/AIDevGallery/ProjectGenerator/Template/MainWindow.xaml.cs @@ -1,21 +1,20 @@ using Microsoft.UI.Xaml; -namespace $safeprojectname$ +namespace $safeprojectname$; + +public sealed partial class MainWindow : Window { - public sealed partial class MainWindow : Window + public MainWindow() { - public MainWindow() + this.InitializeComponent(); + this.RootFrame.Loaded += (sender, args) => { - this.InitializeComponent(); - this.RootFrame.Loaded += (sender, args) => - { - RootFrame.Navigate(typeof($MainSamplePage$)); - }; - } + RootFrame.Navigate(typeof($MainSamplePage$)); + }; + } - internal void ModelLoaded() - { - ProgressRingGrid.Visibility = Visibility.Collapsed; - } + internal void ModelLoaded() + { + ProgressRingGrid.Visibility = Visibility.Collapsed; } -} +} \ No newline at end of file