Ejemplo n.º 1
0
 internal void DeleteButtonClick()
 {
     foreach (PerformerInEntertainmentVM performerInEntertainment in _performerInEntertainmentCollection)
     {
         if (performerInEntertainment.PerformerComparison(AddedSelectedPerformer))
         {
             _deletedPerformerCollection.Add(AddedSelectedPerformer);
             break;
         }
     }
     for (int i = 0; i < _addedPerformerCollection.Count; i++)
     {
         if (PerformerVM.Comparison(_addedPerformerCollection[i], AddedSelectedPerformer))
         {
             _addedPerformerCollection.Remove(_addedPerformerCollection[i]);
             break;
         }
     }
 }
Ejemplo n.º 2
0
 internal void AddButtonClick()
 {
     foreach (PerformerVM performer in _addedPerformerCollection)
     {
         if (PerformerVM.Comparison(performer, PerformerViewModel.SelectedPerformer))
         {
             return;
         }
     }
     for (int i = 0; i < _deletedPerformerCollection.Count; i++)
     {
         if (PerformerVM.Comparison(_deletedPerformerCollection[i], PerformerViewModel.SelectedPerformer))
         {
             _deletedPerformerCollection.Remove(_deletedPerformerCollection[i]);
             break;
         }
     }
     _addedPerformerCollection.Add(PerformerViewModel.SelectedPerformer);
 }