mirror of
https://github.com/Artemis-RGB/Artemis
synced 2026-11-11 19:36:28 +00:00
Profiles - Added module activation requirements
Editor - Refactored tools and selected keyframes management Timeline - Added keyframe duplicating, copying and pasting Windows UI - Added logging of fatal exceptions
This commit is contained in:
1 parent
d563d17270
commit
dd40bdd544
31 files changed
+719
-178
No files matched your search
@@ -1,7 +1,5 @@
|
||||
using Artemis.Core.Services;
|
||||
using Artemis.UI.Shared.Providers;
|
||||
using Artemis.UI.Windows.Ninject;
|
||||
using Artemis.UI.Windows.Providers;
|
||||
using Artemis.UI.Windows.Providers.Input;
|
||||
using Avalonia;
|
||||
using Avalonia.Controls.ApplicationLifetimes;
|
||||
@@ -17,6 +15,7 @@ namespace Artemis.UI.Windows
|
||||
public override void Initialize()
|
||||
{
|
||||
_kernel = ArtemisBootstrapper.Bootstrap(this, new WindowsModule());
|
||||
Program.CreateLogger(_kernel);
|
||||
RxApp.MainThreadScheduler = AvaloniaScheduler.Instance;
|
||||
AvaloniaXamlLoader.Load(this);
|
||||
}
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
using System;
|
||||
using Avalonia;
|
||||
using Avalonia.ReactiveUI;
|
||||
using Ninject;
|
||||
using Serilog;
|
||||
|
||||
namespace Artemis.UI.Windows
|
||||
{
|
||||
@@ -12,7 +14,15 @@ namespace Artemis.UI.Windows
|
||||
[STAThread]
|
||||
public static void Main(string[] args)
|
||||
{
|
||||
BuildAvaloniaApp().StartWithClassicDesktopLifetime(args);
|
||||
try
|
||||
{
|
||||
BuildAvaloniaApp().StartWithClassicDesktopLifetime(args);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Logger?.Fatal(e, "Fatal exception, shutting down");
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
// Avalonia configuration, don't remove; also used by visual designer.
|
||||
@@ -20,5 +30,12 @@ namespace Artemis.UI.Windows
|
||||
{
|
||||
return AppBuilder.Configure<App>().UsePlatformDetect().LogToTrace().UseReactiveUI();
|
||||
}
|
||||
|
||||
private static ILogger? Logger { get; set; }
|
||||
|
||||
public static void CreateLogger(IKernel kernel)
|
||||
{
|
||||
Logger = kernel.Get<ILogger>().ForContext<Program>();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user