/// <summary> /// 正負切り替えボタンがクリックされた /// </summary> /// <param name="sender">イベントのソース</param> /// <param name="e">イベントデータ</param> private void SignToggleButton_Click(object sender, EventArgs e) { switch (state.GetState()) { case ConstDefines.CalcState.Initaial: { state.InputSignToggleInitialState(); break; } case ConstDefines.CalcState.WaitOperation: { state.InputSignToggleWaitOperationInputState(); break; } case ConstDefines.CalcState.WaitNumInputAfterOperation: { state.InputSignToggleWaitNumInputAfterOperationState(); break; } case ConstDefines.CalcState.Calulable: { state.InputSignToggleCalculableState(); break; } default: { state.SetState(ConstDefines.CalcState.Initaial); break; } } }