private void selectPlayer1()
        {
            btn2Player.TintColor  = GHI.Glide.Colors.White;
            btn2Player.TintAmount = 0;
            btn2Player.Invalidate();

            btn1Player.TintColor  = GHI.Glide.Colors.Red;
            btn1Player.TintAmount = 50;
            btn1Player.Invalidate();

            isPlayer1Selected = true;
        }
Esempio n. 2
0
        void OkWait()                               //thread for displaying and refreshing OK button with remaining time
        {
            int i = 5;                              //time in seconds the user has to press OK button until default screen is automatically displayed

            while ((i > 0) && (OkPressed == false)) //if "OK" button is pressed, OkPressed is set to "true" and thread exits
            {
                btnOk.Text = "OK (" + i.ToString() + "sec)";
                btnOk.Invalidate();
                i--;
                Thread.Sleep(1000);               //sleep for 1 second
            }
            if ((i <= 0) && (OkPressed == false)) //if waiting time has passed and user hasn't pushed "OK" button
            {
                displayDefaultScreen();
            }
        }
Esempio n. 3
0
 public static void refreshButton(Window myWindow, GHI.Glide.UI.Button myBtn)
 {
     myWindow.FillRect(myBtn.Rect);
     myBtn.Invalidate();
 }