private void OnDemoTaskJobSettingsClick(object sender, RoutedEventArgs e) { DemoTaskJobSettings settings = this.ViewModel.TaskProcessorFacade.GetTaskJobSettings <DemoTask, DemoTaskJobSettings>(); if (settings == null) { settings = new DemoTaskJobSettings(); } DemoTaskJobSettingsWindow dialog = new DemoTaskJobSettingsWindow(settings); if (dialog.ShowDialog() == true) { this.ViewModel.TaskProcessorFacade.SetTaskJobSettings <DemoTask>(settings); } }
public DemoTaskJobSettingsWindow(DemoTaskJobSettings settings) { this.InitializeComponent(); this.DataContext = settings; }