Exemple #1
0
        public PkMainForm()
        {
            PkSplashForm.ShowSplashScreen();

            this.controller = new PkController();
            this.flying     = false;
            this.data       = PkData.Load();

            this.LogIn();
            this.SynchronizeAccountInfo();

            this.InitForm();
            this.UpdateDaysLeft();
            this.kitePanel.AddKites(this.data.Kites);
            this.StartRenewLoginThread();

            PkLogging.LogPanelUpdate += new EventHandler(this.logPanel.UpdateLog);
            this.logPanel.UpdateLog(this, EventArgs.Empty);

            PkSplashForm.CloseSplashScreen();
        }
Exemple #2
0
        private void LogIn()
        {
            if (this.data.Options.RememberMe)
            {
                PkServiceInfo info = PkService.Login(this.data.ServiceInfo.AccountId, this.data.ServiceInfo.Credentials, true);

                if (info != null)
                {
                    PkLogging.Logger(PkLogging.Level.Info, "Successfully logged in.");
                }
                else
                {
                    PkSplashForm.CloseSplashScreen();
                    this.ShowLoginForm();
                }
            }
            else
            {
                PkSplashForm.CloseSplashScreen();
                this.ShowLoginForm();
            }
        }
 static private void CloseFormInternal()
 {
     splashForm.Close();
     splashForm = null;
 }
 static private void ShowForm()
 {
     splashForm = new PkSplashForm();
     Application.Run(splashForm);
 }
Exemple #5
0
 private static void ShowForm()
 {
     splashForm = new PkSplashForm();
     Application.Run(splashForm);
 }
Exemple #6
0
 private static void CloseFormInternal()
 {
     splashForm.Close();
     splashForm = null;
 }