ConfigFileViewModel.cs 665 B

12345678910111213141516171819202122232425262728293031323334
  1. using CommunityToolkit.Mvvm.ComponentModel;
  2. using CommunityToolkit.Mvvm.Input;
  3. using System;
  4. using System.Collections.Generic;
  5. using System.Linq;
  6. using System.Text;
  7. using System.Threading.Tasks;
  8. namespace ConfigFileManager.ViewModels.Dialog;
  9. internal partial class ConfigFileViewModel : ObservableObject, IDialogAware
  10. {
  11. public DialogCloseListener RequestClose { get; set; }
  12. public bool CanCloseDialog()
  13. {
  14. return true;
  15. }
  16. public void OnDialogClosed()
  17. {
  18. }
  19. public void OnDialogOpened(IDialogParameters parameters)
  20. {
  21. }
  22. [RelayCommand]
  23. private void Close()
  24. {
  25. this.RequestClose.Invoke();
  26. }
  27. }