public MainMenu_Form(User u)
 {
     InitializeComponent();
     currentUser = u;
     currentShift = u.GetOpenShift();
     InitializeFormElements();
     this.Size = DEFAULT_SIZE;
     numVehicle.Value = currentUser.LastVehicleUsed();
 }
        private void LogOutAndReopen()
        {
            Login_Form loginForm = new Login_Form();

            this.Visible = false;
            mainMenuOpen = false;

            if (loginForm.ShowDialog() == DialogResult.OK)
            {
                currentUser = loginForm.currentUser;
                currentShift = currentUser.GetOpenShift();
                lastShift = null;
                InitializeFormElements();
                this.Visible = true;
                chkVehicleLocked.Checked = true;

                if (btnReview.Visible == false)
                {
                    this.Size = DEFAULT_SIZE;
                    lblLastShift.Visible = false;
                    lblLastShiftInformation.Visible = false;
                    btnCloseReviewShifts.Visible = false;
                    btnMoreShiftInformation.Visible = false;
                    btnReview.Visible = true;
                }
                mainMenuOpen = true;
            }
            else
            {
                Application.Exit();
            }
        }