public SubGridVM(SubGrid subGrid, SelectedNumber selectedNumber) { _subGrid = subGrid; Cells = new BindingList <CellVM>(); foreach (Cell cell in _subGrid.Cells) { Cells.Add(new CellVM(cell, selectedNumber)); } }
public SudokuVM() { _mainGrid = new FullGrid(); _selectedNumber = new SelectedNumber { Value = 1 }; _rows = new List <SubCellsVM>(9); _columns = new List <SubCellsVM>(9); SubGrids = new BindingList <SubGridVM>(); InitCells(); InitCommands(); }
public CellVM(Cell cell, SelectedNumber selectedNumber) { _cell = cell; _selectedNumber = selectedNumber; CellClickCmd = new RelayCommand <object>((o) => CellClick()); }