public void AddAroundCell(ICell cell) { if (cell.HasMine) { minesNumber++; } aroundCells.Add(cell); }
public void AddCell(ICell cell, Point2D[] cellContour) { if (cell != null) { SetColor(IntToColor(cells.Count)); cells.Add(cell); Canvas.FillPolygon(brush, cellContour); } }
public void CreateCells(List <CellData> cellsDataList) { foreach (var cellData in cellsDataList) { CellsCollection.Add(new CellBlock(_mainBlockViewModel, cellData)); CellsCollection.Last().PropertyChanged += RowBlockViewModel_PropertyChanged; CellsCollection.Last().SelectMode = _mainBlockViewModel.SelectMode; } }