/// <summary> /// 输出进度条委托信息 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void OutPutTaskProgressBarDelegate(object sender, MainEvents.OutPutTaskProgressBarEventArgs e) { int TaskIndex = e.TaskIndex; int ProgressNum, RecordNum; ProgressNum = e.ProgressNum; RecordNum = e.RecordNum; double fPerNum = double.Parse(ProgressNum.ToString()) / double.Parse(RecordNum.ToString()); double perNumF = double.Parse(fPerNum.ToString("f2")) * 100; int perNum = Convert.ToInt32(perNumF); this.dataGridView_TaskList.Rows[TaskIndex].Cells["ProgressBar"].Value = perNum; }
void Awake() { GameLogic.Instance.UICtrl.SettleUI = this; mWinGo = transform.Find("win").gameObject; mLostGo = transform.Find("lost").gameObject; mPgPositiveImg = transform.Find("progress/positive").GetComponent <Image>(); mPgOppositeImg = transform.Find("progress/opposite").GetComponent <Image>(); mPgAnimImg = transform.Find("progress/animation").GetComponent <Image>(); mPgPositiveNum = new ProgressNum(); mPgOppositeNum = new ProgressNum(); mPgPositiveNum.Init(transform.Find("progress/positivenum")); mPgOppositeNum.Init(transform.Find("progress/oppositenum")); mAvatarGo = transform.Find("avatar").gameObject; mWinGo.SetActive(false); mLostGo.SetActive(false); mPgAnimImg.gameObject.SetActive(false); mAvatarGo.SetActive(false); }