using Valg.EVA.Skanning.UserInterfaceElements.Help;

namespace Valg.EVA.Skanning.JobManagement.Startup.UI.Duplicates
{
    public partial class ViewDuplicateBallotsView : IHelpContributor
    {
        public ViewDuplicateBallotsView()
        {
            InitializeComponent();
            DataContextChanged += ResolveDuplicatesView_DataContextChanged;
        }

        private void ResolveDuplicatesView_DataContextChanged(object sender, System.Windows.DependencyPropertyChangedEventArgs e)
        {
            var viewModel = DataContext as ViewDuplicateBallotsViewModel;
            if (viewModel != null)
            {
                viewModel.CloseWindowAction = (Close);
            }
        }

        public string HelpContributionId => HelpContributionIds.Duplikater;
    }
}
