using Valg.EVA.Skanning.Verify.Startup.Preview;

namespace Valg.EVA.Skanning.Verify.Startup.VerifyBallotPaper.PageXOfY
{
    public class BallotPage
    {
        public BallotPage(IPagedVerificationViewModel viewModel, PageXOfYNavigationTooltip tooltip, PreviewBallotPaperImageViewModel preview)
        {
            ViewModel = viewModel;
            Tooltip = tooltip;
            Preview = preview;
        }

        public int PageNumber
        {
            set
            {
                ViewModel.PageIndex = value - 1;
                Tooltip.PageNumber = value;
                Preview.PageNumber = value;
            }
        }
        public IPagedVerificationViewModel ViewModel { get; }
        public PageXOfYNavigationTooltip Tooltip { get; }
        public PreviewBallotPaperImageViewModel Preview { get; }
    }
}
