Factories and Views
This commit is contained in:
parent
4e7dfc56a8
commit
2529b728ba
16 changed files with 188 additions and 4 deletions
|
|
@ -1,8 +1,28 @@
|
|||
using System.Reactive.Linq;
|
||||
|
||||
using InkForge.Common.ViewModels.Landing;
|
||||
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
using ReactiveUI;
|
||||
|
||||
namespace InkForge.Common.ViewModels;
|
||||
|
||||
public class LandingViewModel : ReactiveObject
|
||||
public class LandingViewModel : ReactiveObject, IScreen
|
||||
{
|
||||
private readonly LandingViewModelFactory _factory;
|
||||
|
||||
public RoutingState Router { get; } = new();
|
||||
|
||||
public LandingViewModel(LandingViewModelFactory factory)
|
||||
{
|
||||
_factory = factory;
|
||||
|
||||
Router.CurrentViewModel.Where(x => x is null)
|
||||
.InvokeCommand<IRoutableViewModel>(Router.NavigateAndReset);
|
||||
}
|
||||
|
||||
public void Navigate<T>() where T : LandingViewModelBase
|
||||
{
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue