Example #1
0
        /// Quit The Application
        public void Quit()
        {
            Restart = false;

            // Quitting Event
            if (loginDialog != null && LoginDialogClosed != null)
            {
                LoginDialogClosed(loginDialog);
                loginDialog.Hide();
                loginDialog.Destroy();
            }
            loginDialog = null;

            if (mainWindow != null && MainWindowClosed != null)
            {
                MainWindowClosed(mainWindow);
                mainWindow.Hide();
                mainWindow.Destroy();
            }
            mainWindow = null;

            // Do User Logout
            if (UserLogout != null)
            {
                UserLogout(myInfo);
            }
            Protocol.MyInfo.Logout();
            this.myInfo = null;
        }
Example #2
0
        private void DoLogin(GUI.Dialogs.Login dialog)
        {
            if (dialog.ValidateInput() == false)
            {
                return;
            }

            if ((myInfo = dialog.CheckLogin()) != null)
            {
                dialog.Destroy();
            }
        }
Example #3
0
        private void DoLogin(GUI.Dialogs.Login dialog)
        {
            if (dialog.ValidateInput() == false)
            {
                return;
            }

            if ((myInfo = dialog.CheckLogin()) != null)
            {
                if (UserLogin != null)
                {
                    UserLogin(myInfo);
                }
                if (LoginDialogClosed != null)
                {
                    LoginDialogClosed(loginDialog);
                }
                dialog.Destroy();
                loginDialog = null;
            }
        }