Example #1
0
        protected override void SetSignal(ResetState newState)
        {
            //translate the message to the guistate enum
            if (newState == ResetState.LEFT) //lib signals left
            {
                GuiState = ResetGuiState.LEFT;
            }
            else if (newState == ResetState.RIGHT) // lib signals right
            {
                GuiState = ResetGuiState.RIGHT;
            }
            else if ((GuiState == ResetGuiState.LEFT || GuiState == ResetGuiState.RIGHT) && newState == ResetState.OFF) //lib signaled last frame, but not now. Start counting
            {
                GuiState = ResetGuiState.DONE;

                //hide done icon later
                Invoke("HideDoneIcon", FadeTimeAfterReset);
            }

            UpdateIcon();
        }
Example #2
0
 void HideDoneIcon()
 {
     GuiState = ResetGuiState.OFF;
     UpdateIcon();
 }