using System; using System.Collections.Generic; using System.ComponentModel; using Gestor.Application.Helpers; namespace Gestor.Application.ViewModels.Generic; public class ErrorDialogViewModel : DialogViewModel, INotifyPropertyChanged { private List> _erros; public List> Erros { get { List> list = new List>(); foreach (KeyValuePair erro in _erros) { list.Add(new KeyValuePair(erro.Key.ToUpper(), erro.Value.ToUpper())); } return list; } set { this.MutateVerbose(ref _erros, value, RaisePropertyChanged(), "Erros"); } } public new event PropertyChangedEventHandler PropertyChanged; private Action RaisePropertyChanged() { return delegate(PropertyChangedEventArgs args) { this.PropertyChanged?.Invoke(this, args); }; } }