Exemplo n.º 1
0
 private void DetachFireFormEvents(FireForm <T> fireForm)
 {
     fireForm.Form <T>().FormClosing -= FormFireManager_OnFormClosing;
     fireForm.Form <T>().FormClosed  -= FormFireManager_OnFormClosed;
     fireForm.Form <T>().Shown       -= FormFireManager_OnShown;
     fireForm.Form <T>().Load        -= FormFireManager_OnLoad;
 }
Exemplo n.º 2
0
 private void imgBtn_Reports_Click(object sender, EventArgs e)
 {
     try
     {
         if (!ActivateForm.NOW("WideForm"))//check the form if its already loaded
         {
             FireForm.Fire("GameTech.B3Reports.Forms.WideForm");
         }
         this.Visible = false;
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }
Exemplo n.º 3
0
        private void imgBtn_Settings_Click(object sender, EventArgs e)
        {
            try
            {
                if (!ActivateForm.NOW("SecurityForm"))//check the form if its already loaded
                {
                    FireForm.Fire("GameTech.B3Reports.Forms.SecurityForm");
                }
                this.Visible = false;
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }


            //  SecurityForm.selectFirstRowListUserNameFromNewMenu();
        }
Exemplo n.º 4
0
        private void imgBtnChangePassword_Click(object sender, EventArgs e)
        {
            try
            {
                LoginFullWin.IschangePassword = true;

                if (!ActivateForm.NOW("loginFullWin"))//check the form if its already loaded
                {
                    FireForm.Fire("GameTech.B3Reports.Forms.loginFullWin");
                }
                else
                {
                    this.Visible = false;
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
Exemplo n.º 5
0
 private void AttachFireFormEvents(FireForm <T> fireForm)
 {
     try
     {
         if (fireForm == null)
         {
             throw new ArgumentNullException(nameof(fireForm), "fireForm parameter must be initalized when MainForm property is initalizing");
         }
         DetachFireFormEvents(fireForm);
         fireForm.Form <T>().FormClosing += FormFireManager_OnFormClosing;
         fireForm.Form <T>().FormClosed  += FormFireManager_OnFormClosed;
         fireForm.Form <T>().Shown       += FormFireManager_OnShown;
         fireForm.Form <T>().Load        += FormFireManager_OnLoad;
         fireForm.Form <T>().Resize      += FormFireManager_OnResize;
     }
     catch (Exception exception)
     {
         throw new FormFireExceptions.FireFormEventException(exception.Message, exception);
     }
 }
Exemplo n.º 6
0
        private void SystemSettings_FormClosing(object sender, FormClosingEventArgs e)
        {
            try
            {
                if (!ActivateForm.NOW("NewMenu"))//check the form if its already loaded
                {
                    FireForm.Fire("GameTech.B3Reports.Forms.NewMenu");
                }
                else
                {
                    this.Visible = false;
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
                //MessageForm.Show(this, mstrFormName + "fixUnitToolStripMenuItem_Click....Exception: " + ex.Message, "Game Management Main");
            }

            clearImage();
        }
Exemplo n.º 7
0
        private void btnLogout(object sender, EventArgs e)
        {
            WriteLog.WriteLog_("", CurrentUserLoggedIn.username, "Logout successful", GetCurrentMacID.MacAddress, "");

            try
            {
                LoginFullWin.IschangePassword = false;
                if (!ActivateForm.NOW("loginFullWin"))//check the form if its already loaded
                {
                    FireForm.Fire("GameTech.B3Reports.Forms.loginFullWin");
                }
                else
                {
                    this.Visible = false;
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }