예제 #1
0
 /// <summary>
 /// Sets the color of the back.
 /// </summary>
 /// <param name="control">The control.</param>
 /// <param name="value">The value.</param>
 public static void SetBackColor(this ButtonBase control, Color value)
 {
     if (control.InvokeRequired)
     {
         control.BeginInvoke(new MethodInvoker(() => control.SetBackColor(value)));
     }
     else
     {
         control.BackColor = value;
         control.Refresh();
     }
 }