-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathApp.xaml.cs
More file actions
30 lines (22 loc) · 873 Bytes
/
App.xaml.cs
File metadata and controls
30 lines (22 loc) · 873 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
using Application = Microsoft.Maui.Controls.Application;
namespace OA.Public.Maui.SampleApp;
public partial class App : Application
{
public static IServiceProvider Services;
public static IAlertService AlertSvc;
public App(IServiceProvider provider)
{
InitializeComponent();
Services = provider;
AlertSvc = Services.GetService<IAlertService>();
TheTheme.SetTheme();
if (Config.Desktop)
MainPage = new DesktopShell();
else
MainPage = new MobileShell();
Routing.RegisterRoute(nameof(AddEditPrinterPage), typeof(AddEditPrinterPage));
Routing.RegisterRoute(nameof(PrintersListPage), typeof(PrintersListPage));
Routing.RegisterRoute(nameof(SettingsPage), typeof(SettingsPage));
Routing.RegisterRoute(nameof(AboutPage), typeof(AboutPage));
}
}