/// <summary>
        /// Constructor
        /// </summary>
        public DataGridViewProgressBarXColumn()
        {
            CellTemplate = new DataGridViewProgressBarXCell();

            _ProgressBarX = new ProgressBarX();
            _ProgressBarX.Visible = false;

            HookEvents(true);
        }
示例#2
0
文件: Main.cs 项目: civicacid/myevo
 public void UpdateProgressBar(ProgressBarX progressBarX, int healtPercentage)
 {
     if (progressBarX.InvokeRequired)
     {
         progressBarX.BeginInvoke(
             new MethodInvoker(
                 delegate { UpdateProgressBar(progressBarX, healtPercentage); }));
     }
     else
     {
         progressBarX.Value = healtPercentage;
     }
 }