using CommunityToolkit.Mvvm.Input; using System.Windows.Media; namespace SummaryModule.Pops.N2Purge; partial class N2PurgeSelectorViewModel : ObservableObject, IDialogAware { public ImageSource? ImageSource { get; set; } = (DrawingImage)Application.Current.Resources["Icon_N2_Purge"]; public string? Title { get; set; } = "Sequence Select"; public DialogCloseListener RequestClose { get; } public bool CanClose() { return true; } public void OnClose() { } public void OnPop(object? state) { this.Mode = "N2 Purge Mode"; } [ObservableProperty] private string? _Mode; [RelayCommand] private void Switch(string para) { this.Mode = para; } [RelayCommand] private void Apply() { this.RequestClose.Invoke(); } public bool CanCloseDialog() { return true; } public void OnDialogClosed() { } public void OnDialogOpened(IDialogParameters parameters) { } }