void m_MultiTask_CheckingTaskChanged(Checker curChecker, CheckTask curTask) { this.AdaptCheckerEvents(curChecker); this.CurrentTask = curTask; if (this.InvokeRequired) { ThreadStart threadStart = delegate { ChangeOperateMode(true); ReadyForCheck(); lblOperateType.Text = "正在检查任务……"; lblOperate.Text = "正在计算检查环境……"; }; this.Invoke(threadStart); } else { ChangeOperateMode(true); ReadyForCheck(); lblOperateType.Text = "正在检查任务……"; lblOperate.Text = "正在计算检查环境……"; } for (int i = 0; i < m_TaskList.Count; i++) { if (m_TaskList[i].ID == curTask.ID) { if (this.InvokeRequired) { ThreadStart threadStart = delegate { clbTask.SelectedIndex = i; }; this.Invoke(threadStart); } else { clbTask.SelectedIndex = i; } break; } } }
void m_MultiTask_TaskChecked(Checker curChecker, CheckTask curTask) { for (int i = 0; i < m_TaskList.Count; i++) { if (m_TaskList[i].ID == curTask.ID) { if (this.InvokeRequired) { ThreadStart threadStart = delegate { clbTask.Items[i].CheckState = CheckState.Checked; }; this.Invoke(threadStart); } else { clbTask.Items[i].CheckState = CheckState.Checked; } break; } } }
void m_MultiTask_CreatingTaskChanged(CheckTask curTask) { this.CurrentTask = curTask; curTask.DataImporter.ImportingObjectChanged += new Check.Task.DataImport.ImportingObjectChangedHandler(DataImporter_ImportingObjectChanged); if (this.InvokeRequired) { ThreadStart threadStart = delegate { lblOperateType.Text = "正在创建任务……"; lblOperate.Text = "正在创建任务结构……"; ChangeOperateMode(false); }; this.Invoke(threadStart); } else { lblOperateType.Text = "正在创建任务……"; lblOperate.Text = "正在创建任务结构……"; ChangeOperateMode(false); } }
void m_MultiTask_TaskCreated(CheckTask curTask) { }