public IEnumerable <IResult> Reset() { var dialog = resultFactory.ShowDialog <NewCurveViewModel>().Configure(m => m.Init(Curve)); yield return(dialog); var newCurve = dialog.Model.NewCurve; if (newCurve != null) { var message = resultFactory.ShowMessageBox(string.Format("Reset {0}?", Curve.Name), "Curve will be reset, continue?", MessageBoxButton.OKCancel); yield return(message); if (message.Result == System.Windows.MessageBoxResult.OK) { Curve.Reset(newCurve); InitCurve(); Name = newCurve.Name; ValidateCurve = true; } } }
public IEnumerable <IResult> ShowAbout() { yield return(resultFactory.ShowDialog <AboutViewModel>()); }