private void BeginAnimation() { if (ReadChanges()) { canvas.Width = settings.GridSize * settings.PixelSize; canvas.Height = settings.GridSize * settings.PixelSize; mainTimer.Interval = settings.TickInterval; Size = new Size(settings.GridSize * settings.PixelSize, settings.GridSize * settings.PixelSize + 30); Grid = new PixelGrid(settings); mainTimer.Stop(); canvas.Invalidate(); this.Invalidate(); btn_Pause.Visible = false; btn_Play.Visible = true; OutSettings(); mainTimer.Stop(); } }
private void SetGrid() { Grid = new PixelGrid(settings); }