/// <summary> /// Redirecting the user to the select source view page /// </summary> private void GoToSelectSource() { // Reset the state to the initial values if (DisplayViewModel.IsBackupDone && !DisplayViewModel.IsBackupRunning) { DisplayViewModel.ResetState(); } // Injecting the SelectSourceViewModel ViewModelLocator.ApplicationViewModel.GoToView(_SelectSourceViewModel); }
/// <summary> /// The action when the user choose backup folder /// </summary> private void SelectDestFolder() { // Reset the state to the initial values if (DisplayViewModel.IsBackupDone && !DisplayViewModel.IsBackupRunning) { DisplayViewModel.ResetState(); } string folder = _DialogService.SelectFolder("Choose folder to backup in hard drive", Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)); if (folder != null) { Details.DestFolder = folder; ViewModelLocator.CacheViewModel.Save(); } }