#pragma warning disable CS8305 // Type is for evaluation purposes only and is subject to change or removal in future updates. public static void InitDispatcher(Microsoft.System.DispatcherQueue dispatcher) #pragma warning restore CS8305 // Type is for evaluation purposes only and is subject to change or removal in future updates. { var platformServices = new WindowsPlatformServices(dispatcher); Device.PlatformServices = platformServices; Device.PlatformInvalidator = platformServices; Registrar.RegisterAll(new[] { typeof(ExportRendererAttribute), typeof(ExportCellAttribute), typeof(ExportImageSourceHandlerAttribute), typeof(ExportFontAttribute) }); IsInitialized = true; Platform.UWP.Platform.SubscribeAlertsAndActionSheets(); }
#pragma warning disable CS8305 // Type is for evaluation purposes only and is subject to change or removal in future updates. public WindowsPlatformServices(Microsoft.System.DispatcherQueue dispatcher) : base(dispatcher) #pragma warning restore CS8305 // Type is for evaluation purposes only and is subject to change or removal in future updates. { }
#pragma warning disable CS8305 // Type is for evaluation purposes only and is subject to change or removal in future updates. protected WindowsBasePlatformServices(Microsoft.System.DispatcherQueue dispatcher) #pragma warning restore CS8305 // Type is for evaluation purposes only and is subject to change or removal in future updates. { _dispatcher = dispatcher ?? throw new ArgumentNullException(nameof(dispatcher)); _uiSettings.ColorValuesChanged += UISettingsColorValuesChanged; }