private void Button_Click_Decimal(object sender, RoutedEventArgs e) { if (!InputBox.Text.Contains(".")) { CalcController.AddTextToInput("."); } }
private void Button_Click_Negate(object sender, RoutedEventArgs e) { // Check if negative exists, if so, remove it, else, add it. if (InputBox.Text.Contains("-")) { InputBox.Text = InputBox.Text.TrimStart('-'); } else { CalcController.AddTextToInput("-", 0); } }
private void Button_Click_6(object sender, RoutedEventArgs e) { CalcController.AddTextToInput("6"); }