persisting view models

This commit is contained in:
2020-02-18 22:07:39 +01:00
parent b910d3a1e6
commit 6ba9c57bd0
3 changed files with 104 additions and 14 deletions

View File

@@ -10,6 +10,9 @@ namespace ModernWpfPlayground
{
ShowDialogCommand = new RelayCommand(async x => await ShowDialogAsync());
CloseCommand = new RelayCommand(x => Application.Current.Shutdown());
OpenViewModelCommand = new RelayCommand(x => LoadViewModel());
SaveViewModelCommand = new RelayCommand(x => SaveViewModel());
ResetViewModelCommand = new RelayCommand(x => ResetViewModel());
}
private async Task ShowDialogAsync()
@@ -52,5 +55,11 @@ namespace ModernWpfPlayground
}
public ICommand CloseCommand { get; }
public ICommand OpenViewModelCommand { get; }
public ICommand SaveViewModelCommand { get; }
public ICommand ResetViewModelCommand { get; }
}
}