mirror of
https://github.com/Artemis-RGB/Artemis
synced 2025-12-13 05:48:35 +00:00
Refactors the setup wizard to streamline the initial user experience. Includes the following changes: - Adds nyan cat animation during feature installations for user enjoyment - Skips essential feature selection if workshop is unreachable - Moves directly to settings after device/surface selection - Adds option to configure settings, after device configuration
44 lines
1.2 KiB
C#
44 lines
1.2 KiB
C#
using System;
|
|
using Artemis.Core;
|
|
using Artemis.Storage;
|
|
using Avalonia;
|
|
using Avalonia.Logging;
|
|
using Avalonia.ReactiveUI;
|
|
using DryIoc;
|
|
using Serilog;
|
|
|
|
namespace Artemis.UI.Windows;
|
|
|
|
internal class Program
|
|
{
|
|
private static ILogger? Logger { get; set; }
|
|
|
|
// Initialization code. Don't use any Avalonia, third-party APIs or any
|
|
// SynchronizationContext-reliant code before AppMain is called: things aren't initialized
|
|
// yet and stuff might break.
|
|
[STAThread]
|
|
public static void Main(string[] args)
|
|
{
|
|
try
|
|
{
|
|
StorageManager.CreateBackup(Constants.DataFolder);
|
|
BuildAvaloniaApp().StartWithClassicDesktopLifetime(args);
|
|
}
|
|
catch (Exception e)
|
|
{
|
|
Logger?.Fatal(e, "Fatal exception, shutting down");
|
|
throw;
|
|
}
|
|
}
|
|
|
|
// Avalonia configuration, don't remove; also used by visual designer.
|
|
public static AppBuilder BuildAvaloniaApp()
|
|
{
|
|
return AppBuilder.Configure<App>().UsePlatformDetect().LogToTrace().UseReactiveUI();
|
|
}
|
|
|
|
public static void CreateLogger(IContainer container)
|
|
{
|
|
Logger = container.Resolve<ILogger>().ForContext<Program>();
|
|
}
|
|
} |