Ejemplo n.º 1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="GamePageViewModel"/> class.
        /// </summary>
        /// <param name="navigationService">NavigationService interface, injected</param>
        /// <param name="step">Step repository interface, injected</param>
        public GamePageViewModel(INavigationService navigationService, IStepRepository step)
        {
            this.navigationService  = navigationService;
            this.NavigateTeam       = new DelegateCommand(this.GoToTeam);
            this.NavigateValidation = new DelegateCommand(this.GoToValidation);
            this.stepRepo           = step;

            CurrentUser.CurrentStep = step.GetCurrentStep(CurrentUser.Player.Id);

            this.ParcoursName    = CurrentUser.CurrentStep.RouteName;
            this.StepName        = CurrentUser.CurrentStep.StepName;
            this.StepDescription = CurrentUser.CurrentStep.StepDescription;
        }