private void Button_Click_Equals(object sender, RoutedEventArgs e) { var equation = OperationBox.Text + InputBox.Text; var result = CalcController.CalculateResult(equation); if (result != null) { CalcController.OverwriteInput(result); CalcController.ClearOperationBox(); } else { CalcController.ClearAll(); } }
private void Button_Click_Clear(object sender, RoutedEventArgs e) { CalcController.ClearAll(); }