public void Edit()
 {
     using (var ecb = new EditCommandButton { CMD = CurButton })
     {
         ecb.ShowDialog(this);
         Constrain(CurButton);
     }
     Invalidate();
 }
 public void Edit()
 {
     using (var ecb = new EditCommandButton {
         CMD = CurButton
     })
     {
         ecb.ShowDialog(this);
         Constrain(CurButton);
     }
     Invalidate();
 }