protected override void OnExamItemStateChanged(ExamItemStateChangedMessage message) { try { if (message.ExamItem.Name == "综合评判") { return; } for (var i = 0; i < AllExamItems.Count(); i++) { if (AllExamItems[i].ItemCode == message.ExamItem.ItemCode) { if (ExamItemState.Progressing == message.NewState) { lstExamItemColor[i] = ColorStateList.ValueOf(ExamProgressingColor); lstExamItemBackGroundColor[i] = Color.Blue; } else if (ExamItemState.Finished == message.NewState) { lstExamItemColor[i] = ColorStateList.ValueOf(ExamFinishedColor); lstExamItemBackGroundColor[i] = Color.Red; } } } RunOnUiThread(ExamItemChange); base.OnExamItemStateChanged(message); } catch (Exception ex) { Logger.Error("DuoLunOnExamItemStateChanged", ex.Message); } base.OnExamItemStateChanged(message); }
//加减挡完成 protected void OnModifyGearOverMessage(ModifyGearOverMessage message) { for (var i = 0; i < AllExamItems.Count(); i++) { if (AllExamItems[i].ItemCode == message.PassedItemCode) { lstExamItemBackGroundColor[i] = Color.ParseColor(finishedColor); currentExam = AllExamItems[i].ItemName; } } //加减挡完成更新加减挡 RunOnUiThread(() => { InitExamItem(); }); }
protected void OnModifyGearOverMessage(ModifyGearOverMessage message) { AddTips("加减挡完成");; for (var i = 0; i < AllExamItems.Count(); i++) { if (AllExamItems[i].ItemCode == message.PassedItemCode) { lstExamItemColor[i] = ColorStateList.ValueOf(Color.Green); currentExam = AllExamItems[i].ItemName; } } //加减挡完成更新加减挡 RunOnUiThread(() => { InitExamItem(); }); }