private void BaseForm_FormClosing(object sender, FormClosingEventArgs e) { BaseForm.log.Trace("BaseForm_FormClosing"); this.notifyIcon.Dispose(); Util.UnInit(); LoopCheckModel.UnInit(); }
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(); } }
private void OnCloseButtonClick() { if (ControlCheckWindow.isAllPass) { AnimationModel.ConnectAnimateionResume(); LoopCheckModel.StartBackgroundCheckControlThread(); } }
private void OnOkClick() { base.Close(); base.Dispose(); if (ControlCheckWindow.isAllPass) { AnimationModel.ConnectAnimateionResume(); LoopCheckModel.StartBackgroundCheckControlThread(); } }
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); } }
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(); }
private void BackClick() { LoopCheckModel.AbortBackgroundCheckControlThread(); if (this.connectModel != null) { this.connectModel.AbortCheckControlReloadThread(); } base.Close(); base.Dispose(); if (this.OnBackClick != null) { this.OnBackClick(); } }
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(); }