mirror of
https://github.com/Artemis-RGB/Artemis
synced 2025-12-12 21:38:38 +00:00
43 lines
1.3 KiB
C#
43 lines
1.3 KiB
C#
using Artemis.UI.Screens.Workshop.CurrentUser;
|
|
using Artemis.UI.Screens.Workshop.SubmissionWizard.Models;
|
|
using Artemis.UI.Screens.Workshop.SubmissionWizard.Steps;
|
|
using Artemis.UI.Shared;
|
|
using Artemis.UI.Shared.Services;
|
|
using DryIoc;
|
|
using PropertyChanged.SourceGenerator;
|
|
|
|
namespace Artemis.UI.Screens.Workshop.SubmissionWizard;
|
|
|
|
public partial class SubmissionWizardViewModel : ActivatableViewModelBase, IWorkshopWizardViewModel
|
|
{
|
|
private readonly SubmissionWizardState _state;
|
|
private SubmissionViewModel _screen;
|
|
[Notify] private bool _shouldClose;
|
|
|
|
public SubmissionWizardViewModel(IContainer container,
|
|
IWindowService windowService,
|
|
CurrentUserViewModel currentUserViewModel,
|
|
WelcomeStepViewModel welcomeStepViewModel)
|
|
{
|
|
_state = new SubmissionWizardState(this, container, windowService);
|
|
_screen = welcomeStepViewModel;
|
|
_screen.State = _state;
|
|
|
|
WindowService = windowService;
|
|
CurrentUserViewModel = currentUserViewModel;
|
|
CurrentUserViewModel.AllowLogout = false;
|
|
}
|
|
|
|
public IWindowService WindowService { get; }
|
|
public CurrentUserViewModel CurrentUserViewModel { get; }
|
|
|
|
public SubmissionViewModel Screen
|
|
{
|
|
get => _screen;
|
|
set
|
|
{
|
|
value.State = _state;
|
|
RaiseAndSetIfChanged(ref _screen, value);
|
|
}
|
|
}
|
|
} |