Ejemplo n.º 1
0
 private void btnOk_Click(object sender, EventArgs e)
 {
     try
     {
         _booSaveInput  = true;
         _ButtonPressed = eButtons.Ok;
         this.Close();
     }
     catch (Exception)
     {
         throw;
     }
 }
Ejemplo n.º 2
0
 private void btnCancel_Click(object sender, EventArgs e)
 {
     try
     {
         txtUserInput.Text = "";
         txtDuration.Text  = "00:00:00";
         _booSaveInput     = false;
         _ButtonPressed    = eButtons.Cancel;
         this.Close();
     }
     catch (Exception)
     {
         throw;
     }
 }
Ejemplo n.º 3
0
    public bool checkPressedButton(eButtons button)
    {
        bool result = false;

        if (button == (eButtons)sequence[currentIndex])
        {
            //OK
            game.soundSequence(false);
            updateButton(currentIndex, sequence[currentIndex], eStatus.OK);
            currentIndex++;
            result = true;
        }
        else
        {
            //KO
            //Meter un delay
            StartCoroutine(delayOnError(.5f));
        }
        return(result);
    }