示例#1
0
 private void BaseForm_FormClosing(object sender, FormClosingEventArgs e)
 {
     BaseForm.log.Trace("BaseForm_FormClosing");
     this.notifyIcon.Dispose();
     Util.UnInit();
     LoopCheckModel.UnInit();
 }
示例#2
0
 private void ShowControlByStatus(int status)
 {
     if (status == -1000)
     {
         this.ShowCheckControl();
         return;
     }
     if (status == -2000)
     {
         this.ShowRebootControl();
         return;
     }
     if (status == -1001)
     {
         this.ShowRouterControl();
         return;
     }
     if (status == -1002)
     {
         this.ShowRaspberryControl();
         return;
     }
     if (status == -3000)
     {
         this.ShowCableControl();
         return;
     }
     if (status == 0)
     {
         base.Close();
         base.Dispose();
         AnimationModel.ConnectAnimateionResume();
         LoopCheckModel.StartBackgroundCheckControlThread();
     }
 }
示例#3
0
 private void OnCloseButtonClick()
 {
     if (ControlCheckWindow.isAllPass)
     {
         AnimationModel.ConnectAnimateionResume();
         LoopCheckModel.StartBackgroundCheckControlThread();
     }
 }
示例#4
0
 private void OnOkClick()
 {
     base.Close();
     base.Dispose();
     if (ControlCheckWindow.isAllPass)
     {
         AnimationModel.ConnectAnimateionResume();
         LoopCheckModel.StartBackgroundCheckControlThread();
     }
 }
示例#5
0
 private void switchChannel_Click(object sender, EventArgs e)
 {
     if (!ControlCheckWindow.isChecking)
     {
         LoopCheckModel.AbortBackgroundCheckControlThread();
         Util.showGrayBackground();
         new NetworkDialog
         {
             OnBackClick = new NetworkDialog.OnBackClickDelegate(this.networkDialogBackClick)
         }.Show(Util.sContext);
     }
 }
示例#6
0
 private void OnWirelessFinish()
 {
     ControlCheckWindow.isChecking = false;
     ControlCheckWindow.isAllPass  = true;
     this.progressBox.Image        = Resources.connect_success_progress;
     this.indicatorWireless.Image  = Resources.vr_success;
     this.routerLabel.Visible      = false;
     this.raspberryLabel.Visible   = false;
     this.systemLabel.Visible      = false;
     this.messageLabel.Text        = Resources.messageSuccess;
     this.messageLabel.Visible     = true;
     LoopCheckModel.StartBackgroundCheckControlThread();
 }
示例#7
0
 private void BackClick()
 {
     LoopCheckModel.AbortBackgroundCheckControlThread();
     if (this.connectModel != null)
     {
         this.connectModel.AbortCheckControlReloadThread();
     }
     base.Close();
     base.Dispose();
     if (this.OnBackClick != null)
     {
         this.OnBackClick();
     }
 }
示例#8
0
 public MainForm()
 {
     this.InitializeComponent();
     Util.Init(this);
     ConfigureUtil.init(this);
     Client.init(this);
     NetworkUtil.Init(this);
     LoopCheckModel.Init(this);
     ThreadPool.RegisterWaitForSingleObject(Program.ProgramStarted, new WaitOrTimerCallback(this.OnProgramStarted), null, -1, false);
     this.appLabel.Text            = Resources.titleText;
     this.backgroundImage.SizeMode = PictureBoxSizeMode.StretchImage;
     this.backgroundImagePanel.BringToFront();
     System.Timers.Timer expr_79 = new System.Timers.Timer(2000.0);
     expr_79.Elapsed           += new ElapsedEventHandler(this.dismissBackgroundImage);
     expr_79.AutoReset          = false;
     expr_79.Enabled            = true;
     this.OnTimerFinishListener = new MainForm.OnTimerFinishDelegate(this.OnTimerFinish);
     LoopCheckModel.setConnectLoopInterruptCallback(this);
     this.OnRecommendedUpdateClick = new BaseForm.OnRecommendedUpdateClickDelegate(this.recommendedUpdateClick);
     this.OnUpdateDialogClose      = new BaseForm.OnUpdateDialogCloseDelegate(this.updateDialogClose);
     this.OnNetworkDialogBackClick = new BaseForm.OnNetworkDialogBackClickDelegate(this.ShowControlCheckWindow);
     this.ShowControlCheckWindow();
 }