Exemplo n.º 1
0
        private void InitUI_UcCalibration_ESC()
        {
            // all Buttons setup
            this.InitUI_UcCalibration_ESC_Buttons();

            // all Labels setups
            this.InitUI_UcCalibration_ESC_Labels();

            this.CurrentStep = ESC_STEPS.STEP1;

            // Timer setup.
            this.InitUI_UcCalibration_ESC_Timer();
        }
Exemplo n.º 2
0
        /// <summary>
        /// Previous and Next buttons click event.
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void StepButton_Click(object sender, EventArgs e)
        {
            Button button = (Button)sender;

            int step = Convert.ToInt32(this.CurrentStep);

            if (button.Equals(this.ButtonPrevious))
            {
                if (step == 0)
                {
                    return;
                }
                this.CurrentStep = (ESC_STEPS)(step - 1);
            }
            else
            {
                if (step == 6)
                {
                    this.CurrentStep = ESC_STEPS.STEP1;
                    return;
                }
                this.CurrentStep = (ESC_STEPS)(step + 1);
            }
        }