forked from reactiveui/ReactiveUI
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathApp.cs
More file actions
33 lines (28 loc) · 1010 Bytes
/
App.cs
File metadata and controls
33 lines (28 loc) · 1010 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
31
32
using System;
using ReactiveUI;
using System.Collections.Generic;
using System.Linq;
using ReactiveUI.Mobile;
using Splat;
namespace AndroidPlayground
{
public class App
{
static App _Current;
public static App Current {
get { return (_Current = _Current ?? new App()); }
}
protected App()
{
// TODO: Fix Me
//RxApp.ConfigureServiceLocator(
// (t, s) => locator.GetAllServices(t, s).FirstOrDefault(),
// (t, s) => locator.GetAllServices(t, s).ToArray(),
// (c, t, s) => locator.Register(() => Activator.CreateInstance(c), t, s));
Locator.CurrentMutable.Register(() => typeof(MainView), typeof(IViewFor<MainViewModel>));
Locator.CurrentMutable.Register(() => typeof(SecondaryView), typeof(IViewFor<SecondaryViewModel>));
// TODO: Fix Me
//RxApp.Register(typeof(AppBootstrapper), typeof(IApplicationRootState));
}
}
}