public ConfigurationViewModel(IDiceService diceService, IDiceDataBase diceDataBase) { //first step _diceService = diceService; _diceDataBase = diceDataBase; ResetBagCommand = new Command(ExecuteResetBagCommand); }
public MasterViewModel(IDiceService diceService, IDiceDataBase diceDataBase) { //first step _diceService = diceService; _diceDataBase = diceDataBase; ListBag = new ObservableCollection <Bag>(); CreateNewBagCommand = new Command(ExecuteCreateNewBagCommand); GoConfigurationCommand = new Command(ExecuteGoConfigurationCommand); }
public BagViewModel(IDiceService diceService, IDiceDataBase diceDataBase, Bag bag) { //first step _diceService = diceService; _diceDataBase = diceDataBase; Bag = bag; ListGroupDice = new ObservableCollection <GroupDice>(); MarkItem = new List <GroupDice>(); //Commands GroupDicePageCommand = new Command(ExecuteGroupDicePageCommand); //Set proprety CreateBagState(); LoadDataToObject(); }
public RoomViewModel(IDiceService diceService, IDiceDataBase diceDataBase, Bag bag = null) { _diceService = diceService; _diceDataBase = diceDataBase; Bag = bag == null?GetBagConfiguration() : bag; IsLoading = false; GroupDices = new CustomObservableCollection <GroupDice>(); LogRoll = new CustomObservableCollection <LogRoll>(); //Commands RollDiceCommand = new Command <GroupDice>(ExecuteRollDiceCommand); BagPageCommand = new Command(ExecuteBagPageCommand); ResetBagCommand = new Command(ExecuteResetBagCommand); ClearLogCommand = new Command(ExecuteClearLogCommand); }
public GroupDiceViewModel(IDiceService diceService, IDiceDataBase diceDataBase, Bag bag) { //first step _diceService = diceService; _diceDataBase = diceDataBase; Bag = bag; ListDices = new ObservableCollection <Dice>(); ListDices.Add(new Dice() { Quantity = 1, NumberFaceOfDice = 20 }); //Command AddDiceCommand = new Command(ExecuteAddDiceCommand); RemoveLastDiceCommand = new Command(ExecuteRemoveLastDiceCommand); SaveCommand = new Command(ExecuteSaveCommand); CancelDiceCommand = new Command(ExecuteCancelDiceCommand); AddModifierCommand = new Command(ExecuteAddModifierCommand); }