//Operator State private void DigitPeriod_Button_MouseClick(object sender, MouseEventArgs e) { string input = DigitPeriod_Button.Text; CalculatorState.getInstance().nextState(1, input); textBox1.Text = CalculationState.getInstance().display(); }
private void Digit7_Button_Click(object sender, EventArgs e) { string input = Digit7_Button.Text; CalculatorState.getInstance().nextState(1, input); textBox1.Text = CalculationState.getInstance().clearScreen(); textBox1.Text = CalculationState.getInstance().display(); }
//Calculation State private void ComputeButton_MouseClick(object sender, MouseEventArgs e) { CalculatorState.getInstance().nextState(3, null); textBox1.Text = CalculationState.getInstance().display(); }