Ejemplo n.º 1
0
 /// <summary>
 /// Method that adds a game to the shopping cart and updates it
 /// </summary>
 public void AddGame()
 {
     _shoppingCart.AddGame(SelectedGame);
     OnPropertyChanged(nameof(Games));
     OnPropertyChanged(nameof(TotalPrice));
     OnPropertyChanged(nameof(IsCheckoutEnabled));
 }
Ejemplo n.º 2
0
 private void BuyGameButton_OnClick(object sender, RoutedEventArgs e)
 {
     _shoppingCart.AddGame(_gameList.SelectedGame);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Adds SelectedGame to the shopping cart, then refreshes it in the mainpage.
 /// </summary>
 public void PurchaseSelectedGame()
 {
     _shoppingCart.AddGame(SelectedGame);
     _shoppingCart.MainPageVm.RefreshPurchaseSelectedGame();
 }