public PrizeLevelBox(DivisionUC div, LevelBox box) { InitializeComponent(); division = div; levelModel = box; levelBox.DataContext = levelModel; prizeLevelLabel.DataContext = levelModel; }
public PrizeLevelBox(DivisionUC div, LevelBox box) { InitializeComponent(); division = div; levelModel = box; levelBox.DataContext = levelModel; prizeLevelLabel.DataContext = levelModel; }
public DivisionUC(PrizeLevels.PrizeLevels initialPrizeLevels, int number) { InitializeComponent(); DivModel = new DivisionModel(); setDataContextToModel(); Prizes = initialPrizeLevels; DivModel.DivisionNumber = number; for (int i = 0; i < DivisionModel.MAX_PRIZE_BOXES; i++) { LevelBox levelBox = new LevelBox(i + 1); DivModel.levelBoxes.Add(levelBox); PrizeLevelBox box = new PrizeLevelBox(this, DivModel.levelBoxes[i]); if (i < initialPrizeLevels.getNumPrizeLevels()) box.levelModel.IsAvailable = true; prizeLevelsGrid.Children.Add(box); } }
public DivisionUC(PrizeLevels.PrizeLevels initialPrizeLevels, int number) { InitializeComponent(); DivModel = new DivisionModel(); setDataContextToModel(); Prizes = initialPrizeLevels; DivModel.DivisionNumber = number; for (int i = 0; i < DivisionModel.MAX_PRIZE_BOXES; i++) { LevelBox levelBox = new LevelBox(i + 1); DivModel.levelBoxes.Add(levelBox); PrizeLevelBox box = new PrizeLevelBox(this, DivModel.levelBoxes[i]); if (i < initialPrizeLevels.getNumPrizeLevels()) { box.levelModel.IsAvailable = true; } prizeLevelsGrid.Children.Add(box); } }