Program.cs 994 B

1234567891011121314151617181920212223242526272829303132
  1. using System;
  2. using Avalonia;
  3. using InABox.Avalonia.Platform;
  4. using InABox.Avalonia.Platform.Desktop;
  5. namespace PRS.Avalonia.Desktop;
  6. sealed class Program
  7. {
  8. // Initialization code. Don't use any Avalonia, third-party APIs or any
  9. // SynchronizationContext-reliant code before AppMain is called: things aren't initialized
  10. // yet and stuff might break.
  11. [STAThread]
  12. public static void Main(string[] args) => BuildAvaloniaApp()
  13. .StartWithClassicDesktopLifetime(args);
  14. // Avalonia configuration, don't remove; also used by visual designer.
  15. public static AppBuilder BuildAvaloniaApp()
  16. {
  17. PlatformTools.Register<IPdfRenderer, Desktop_PdfRenderer>();
  18. PlatformTools.Register<IBluetooth, Desktop_Bluetooth>();
  19. PlatformTools.Register<IAppVersion, Desktop_AppVersion>();
  20. return AppBuilder.Configure<App>()
  21. .UsePlatformDetect()
  22. .WithInterFont()
  23. .LogToTrace();
  24. }
  25. }