public Form_MsgDebug(Form_Pars formMain) { if (null != formMain) { form_Pars = formMain; dp = (DockPanel)formMain.Controls["dockPanel1"]; form_Pars.ParentFormEvent += Form_Pars_ParentFormEvent; } }
private void DDCServerToolStripMenuItem_Click(object sender, EventArgs e) { ToolStripMenuItem tmi = sender as ToolStripMenuItem; switch (tmi.Text) { case "ATMC": case "DDCServer": case "DDCServer-2": case "NDCServer": case "NDCServer-2": case "VirtualDualHost": { isAlreadyNDC_1 = false; isAlreadyNDC_2 = false; isAlareadyDualHost = false; isAlreadyDDC_1 = false; isAlreadyDDC_2 = false; isATMC = false; foreach (DockContent dockContent in dockPanel1.Contents) { if (dockContent.Name.Equals("Form_NDCServer")) { isAlreadyNDC_1 = true; } else if (dockContent.Name.Equals("Form_NDCServer_2")) { isAlreadyNDC_2 = true; } else if (dockContent.Name.Equals("Form_DDCServer")) { isAlreadyDDC_1 = true; } else if (dockContent.Name.Equals("Form_DDCServe2")) { isAlreadyDDC_2 = true; } else if (dockContent.Name.Equals("Form_DualHost")) { isAlareadyDualHost = true; } else if (dockContent.Name.Equals("Form_Managerment")) { isATMC = true; } if (tmi.Text.Equals(dockContent.Text)) { dockContent.Select(); break; } } if (tmi.Text == "NDCServer_2" && !isAlreadyNDC_2) { Form_NDCServer_2 form_NDCServer2 = new Form_NDCServer_2(); form_NDCServer2.Show(this.dockPanel1, DockState.Document); } else if (tmi.Text == "NDCServer" && !isAlreadyNDC_1) { Form_NDCServer form_NDCServer1 = new Form_NDCServer(); form_NDCServer1.Show(this.dockPanel1, DockState.Document); } else if (tmi.Text == "DDCServer" && !isAlreadyDDC_1) { Form_DDCServer form_DDCServer1 = new Form_DDCServer(); form_DDCServer1.Show(this.dockPanel1, DockState.Document); } else if (tmi.Text == "DDCServer_2" && !isAlreadyDDC_2) { MessageBox.Show("Comming Soon..."); } else if (tmi.Text == "VirtualDualHost" && !isAlareadyDualHost) { Form_DualHost form_DualHost = new Form_DualHost(); form_DualHost.Show(this.dockPanel1, DockState.Document); } else if (tmi.Text == "ATMC" && !isATMC) { form_managerMentMain.Show(this.dockPanel1, DockState.Document); } } break; case "SuperParse": { Form_Pars form_Pars = new Form_Pars(); form_Pars.Show(); } break; case "ScreenParse": { Form_ScreenParse form_screenPars = new Form_ScreenParse(); form_screenPars.Show(); } break; case "eCAT": { From_Seeting_eCATPath form_eCAT = new From_Seeting_eCATPath(); form_eCAT.Show(); } break; case "KilleCAT": { KilleCATFunc(); } break; case "StarteCAT": { StarteCATFunc(); } break; case "eCATConfigTool": { System.Threading.Thread eCATToolThread = new System.Threading.Thread(eCATConfigToolFunc); eCATToolThread.IsBackground = true; eCATToolThread.Start(); //eCATConfigToolFunc(); } break; case "Open-eCAT": { //打开eCAT路径 XDCUnity.OpenPath(XDCUnity.eCATPath); } break; case "Open-XDCHost": { //打开当前主机路径 XDCUnity.OpenPath(Environment.CurrentDirectory); } break; case "Open-TrueBack": { //打开当前主机路径 CheckTrueBackPath(); string truebackPath = XDCUnity.TrueBackPath; truebackPath = truebackPath.Substring(0, truebackPath.LastIndexOf('\\')); XDCUnity.OpenPath(truebackPath); } break; case "ErrorCode": { Form_ErrorCodeSearch form_errorcode = new Form_ErrorCodeSearch(); form_errorcode.Show(); } break; case "InteractiveBuffer": { new Form_GetInteractiveMsgTextToShow("").Show(); } break; case "About": { new Form_About().ShowDialog(); } break; case "ImportLogsToAutoReply": { new Form_ImportLogs().Show(); } break; case "Exit": { this.Close(); } break; case "C09": { new Form_C09().Show(); } break; default: break; } }
public Form_ManuSendLeft(Form_Pars formMain) { Control.CheckForIllegalCrossThreadCalls = false; form_Pars = formMain; dp = (DockPanel)formMain.Controls["dockPanel1"]; }