Example #1
0
 public User()
 {
     this.idNumber = 0;
     this.lInType  = LogInType.None;
     this.fname    = "";
     this.lname    = "";
 }
Example #2
0
 public User()
 {
     this.idNumber = 0;
     this.lInType = LogInType.None;
     this.fname = "";
     this.lname = "";
 }
Example #3
0
        private void FormMain_Load(object sender, EventArgs e)
        {
            currentLogInType = LogInType.None;
            SetUiToLoginType();
            Connection con = new Connection();

            Connection.Instance = con;
            Connection.Instance.Connect();
        }
Example #4
0
 /// <summary>
 /// log in into the control
 /// </summary>
 /// <param name="loginType"></param>
 void LogIN(LogInType loginType)
 {
     currentLogInType = loginType;
     SetUiToLoginType();
     if (currentLogInType == LogInType.Admin)
     {
         textBoxMenu.Text = "Admin";
     }
     else
     {
         textBoxMenu.Text = "Super Admin";
     }
 }
        /// <summary>
        /// Shows whenever player logged in or just registered
        /// </summary>
        /// <param name="logInType"></param>
        public void ShowPlayerLoggedIn(LogInType logInType)
        {
            switch (logInType)
            {
            case LogInType.Registered:
                Debug.Log("Welcome to Match3Fighter, new player!");
                break;

            case LogInType.SignedIn:
                Debug.Log("Welcome back!");
                break;

            default:
                throw new ArgumentOutOfRangeException(nameof(logInType), logInType, null);
            }
        }
Example #6
0
        private void bunifuFlatButtonLogOut_Click_1(object sender, EventArgs e)
        {
            if (panelSideMenu.Width == 100)
            {
                panelSideMenu.Width = 335;
            }
            else
            {
                List <int> test = new List <int>();

                for (int i = 0; i < panelLogin.Controls.Count; i++)
                {
                    if (panelLogin.Controls[i] is UcInsertData)
                    {
                        test.Add(i);
                    }
                    else if (panelLogin.Controls[i] is UcInsertCommission)
                    {
                        test.Add(i);
                    }
                    else if (panelLogin.Controls[i] is UcReport)
                    {
                        test.Add(i);
                    }
                    else if (panelLogin.Controls[i] is UcSetting)
                    {
                        test.Add(i);
                    }
                }

                for (int i = 0; i < test.Count; i++)
                {
                    panelLogin.Controls.RemoveAt(test[i]);
                }

                currentLogInType = LogInType.None;
                SetUiToLoginType();
                ClearUI();
                ClosePanel();
            }
        }
Example #7
0
 /// <summary>
 /// logs out of the control
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void bunifuFlatButtonLogOut_Click(object sender, EventArgs e)
 {
     currentLogInType = LogInType.None;
     SetUiToLoginType();
     ClearUI();
 }