private void CloseToggleDataView(object sender, EventArgs e) { var multipleToggleModel = (FormatOptionMultipleToggleModel)selectedOption; var toggleMultipleDataView = (ToggleMultipleDataView)sender; multipleToggleModel.ToggleFlags = ((ToggleMultipleDataViewModel)toggleMultipleDataView.DataContext).Input; toggleMultipleDataView.Closed -= CloseInputDataView; if (CloseMultipleInput != null) { CloseMultipleInput.Invoke(sender, e); } }
private void CloseInputDataView(object sender, EventArgs e) { var multipleInputModel = (FormatOptionMultipleInputModel)selectedOption; var inputMultipleDataView = (InputMultipleDataView)sender; multipleInputModel.MultipleInput = ((InputMultipleDataViewModel)inputMultipleDataView.DataContext).Input; inputMultipleDataView.Closed -= CloseInputDataView; if (CloseMultipleInput != null) { CloseMultipleInput.Invoke(sender, e); } }