/// <summary> /// テキストボックスのエラーが解決されたときに「OK」ボタンを有効にする /// </summary> private void TextBoxOnError解除Button有効無効() { if (this.swvm.OdeSolver == DefaultData.OdeSolverType.ADAMS_BASHFORTH_MOULTON && (this.IsOutputToCsvFileCheckBox.IsChecked ?? false) && this.swvm.GetErrors("DeltatOfOdeSolver") == null && this.swvm.GetErrors("IntervalOfOutputToCsvFile") == null) { this.OkButton.IsEnabled = true; } else if (this.swvm.OdeSolver == DefaultData.OdeSolverType.ADAMS_BASHFORTH_MOULTON && !(this.IsOutputToCsvFileCheckBox.IsChecked ?? false) && this.swvm.GetErrors("DeltatOfOdeSolver") == null) { this.OkButton.IsEnabled = true; } else if (this.swvm.OdeSolver != DefaultData.OdeSolverType.ADAMS_BASHFORTH_MOULTON && !(this.IsOutputToCsvFileCheckBox.IsChecked ?? false) && this.swvm.GetErrors("DeltatOfOdeSolver") == null && this.swvm.GetErrors("EpsOfSolveOde") == null) { this.OkButton.IsEnabled = true; } else if (this.swvm.OdeSolver != DefaultData.OdeSolverType.ADAMS_BASHFORTH_MOULTON && (this.IsOutputToCsvFileCheckBox.IsChecked ?? false)) { UtilityFunc.TextBoxOnError解除Button有効(this.OkButton, this.swvm); } else { this.OkButton.IsEnabled = false; } }
/// <summary> /// 「EpsOfSolveOdeTextBox」がエラーを検知したときに呼ばれるイベントハンドラ /// </summary> /// <param name="sender">The parameter is not used.</param> /// <param name="e">The parameter is not used.</param> private void EpsOfSolveOdeTextBox_OnError(object sender, ValidationErrorEventArgs e) { this.swvm.EpsOfSolveOdeHasError = UtilityFunc.TextBoxOnErrorButton無効(this.OkButton, "EpsOfSolveOde", this.swvm); }
/// <summary> /// 「IntervalOfOutputToCsvFileTextBox」がエラーを検知したときに呼ばれるイベントハンドラ /// </summary> /// <param name="sender">The parameter is not used.</param> /// <param name="e">The parameter is not used.</param> private void IntervalOfOutputToCsvFileTextBox_OnError(object sender, ValidationErrorEventArgs e) { this.swvm.IntervalOfOutputToCsvFileHasError = UtilityFunc.TextBoxOnErrorButton無効(this.OkButton, "IntervalOfOutputToCsvFile", this.swvm); }
/// <summary> /// 「DeltatOfOdeSolverTextBox」がエラーを検知したときに呼ばれるイベントハンドラ /// </summary> /// <param name="sender">The parameter is not used.</param> /// <param name="e">The parameter is not used.</param> private void DeltatOfOdeSolverTextBox_OnError(object sender, ValidationErrorEventArgs e) { this.swvm.DeltatOfOdeSolverHasError = UtilityFunc.TextBoxOnErrorButton無効(this.OkButton, "DeltatOfOdeSolver", this.swvm); }