public void SnakeField_SnakeFieldCreated(SnakeField sender)
 {
     Brush snakeFieldBrush;
     snakeFieldBrush = new SolidBrush(Properties.GraphicColorSettings.Default.CurrentSnakeFieldColor);
     int snakeFieldX = graphicLocationX + sender.Col * this.fieldSize;
     int snakeFieldY = graphicLocationY + sender.Row * this.fieldSize;
     lock (this.matrixGraphic)
     {
         this.matrixGraphic.FillRectangle
             (snakeFieldBrush, snakeFieldX, snakeFieldY, this.fieldSize, this.fieldSize);
     }
     snakeFieldBrush.Dispose();
 }
 public void SnakeField_SnakeFieldSmoothCreation(SnakeField sender)
 {
     Brush snakeFieldBrush = new SolidBrush(Properties.GraphicColorSettings.Default.CurrentSnakeFieldColor);
     int snakeFieldX = graphicLocationX + sender.Col * this.fieldSize;
     int snakeFieldY = graphicLocationY + sender.Row * this.fieldSize;
     this.matrixGraphic.SmoothFillRectangleMultithreading
         (snakeFieldBrush, new Point(snakeFieldX, snakeFieldY), new Size(this.fieldSize, this.fieldSize), directionsDict[sender.DrawDirection], this.timeInterval);
     snakeFieldBrush.Dispose();
 }
 private void PutIntoMatrix(int row, int col, Field[,] currentMatrix,Directions drawDirection)
 {
     currentMatrix[row, col] = new SnakeField(row,col,drawDirection);
 }