private void btnSearch_Click(object sender, EventArgs e)
 {
     activeBar.Height = btnSearch.Height - 1;
     activeBar.Top    = btnSearch.Top;
     if (!home.Instance.PnlLeft.Controls.ContainsKey("controlSearchAnimal"))
     {
         controlSearchAnimal search = new controlSearchAnimal();
         search.Dock = DockStyle.Fill;
         home.Instance.PnlContainer.Controls.Add(search);
     }
     home.Instance.PnlContainer.Controls["controlSearchAnimal"].BringToFront();
 }
Пример #2
0
 private void btnSearch_Click(object sender, EventArgs e)
 {
     /* Active button of the main menu set as the SEARCH button */
     activeBar.Height = btnSearch.Height - 1;
     activeBar.Top    = btnSearch.Top;
     /* Add Content Search in MAIN BOX */
     if (!home.Instance.PnlLeft.Controls.ContainsKey("controlSearchAnimal"))
     {
         controlSearchAnimal search = new controlSearchAnimal();
         search.Dock = DockStyle.Fill;
         home.Instance.PnlContainer.Controls.Add(search);
     }
     home.Instance.PnlContainer.Controls["controlSearchAnimal"].BringToFront();
 }
Пример #3
0
        private void btnUserMenu_Click(object sender, EventArgs e)
        {
            /* Active button of the main menu set as the USER MENU button */
            activeBar.Height = btnUserMenu.Height - 1;
            activeBar.Top    = btnUserMenu.Top;
            /* Change to USER MENU */
            if (!home.Instance.PnlLeft.Controls.ContainsKey("controlUserMenu"))
            {
                controlUserMenu userMenu = new controlUserMenu();
                userMenu.Dock = DockStyle.Fill;
                home.Instance.PnlLeft.Controls.Add(userMenu);
            }
            home.Instance.PnlLeft.Controls["controlUserMenu"].BringToFront();
            /* Add Content Search in main box */
            controlSearchAnimal search = new controlSearchAnimal();

            search.Dock = DockStyle.Fill;
            home.Instance.PnlContainer.Controls.Add(search);
            home.Instance.PnlContainer.Controls["controlSearchAnimal"].BringToFront();
            home.Instance.BackButton.Visible = true;
        }
Пример #4
0
 private void btnEnter_Click(object sender, EventArgs e)
 {
     _passInput = PassInput();
     if (!_passInput.Equals(password))
     {
         incorrectPass.Visible = true;
     }
     else
     {
         if (!home.Instance.PnlLeft.Controls.ContainsKey("controlAdminMenu"))
         {
             controlAdminMenu adminMenu = new controlAdminMenu();
             adminMenu.Dock = DockStyle.Fill;
             home.Instance.PnlLeft.Controls.Add(adminMenu);
         }
         home.Instance.PnlLeft.Controls["controlAdminMenu"].BringToFront();
         home.Instance.BackButton.Visible = true;
         controlSearchAnimal search = new controlSearchAnimal();
         search.Dock = DockStyle.Fill;
         home.Instance.PnlContainer.Controls.Add(search);
         home.Instance.PnlContainer.Controls["controlSearchAnimal"].BringToFront();
         home.Instance.BackButton.Visible = true;
     }
 }