private void SupprimerCritere() { foreach (ReviewDisplay revD in ReviewsD.ToList()) { int _nbTags = revD.Tags.Count; int _nbUnselected = 0; if (revD.Tags.Contains(ReviewTypes.Drink.ToString()) && !_isDrinkChecked) { _nbUnselected++; } if (revD.Tags.Contains(ReviewTypes.ToSee.ToString()) && !_isToSeeChecked) { _nbUnselected++; } if (revD.Tags.Contains(ReviewTypes.Food.ToString()) && !_isFoodChecked) { _nbUnselected++; } if (_nbTags == _nbUnselected) { ReviewsD.Remove(revD); } } }
private void RechercheTitre() { SetReviews(); if (!EntryRecherche.Equals("")) { ReviewsD = new ObservableCollection <ReviewDisplay>(ReviewsD.Where(rev => rev.Titre.ToLower().Contains(EntryRecherche.ToLower()))); } }
private void AjouterCritere(string Tag) { foreach (ReviewDisplay revD in _loadedReviewsD) { if (revD.Tags.Contains(Tag) && !ReviewsD.Contains(revD)) { ReviewsD.Add(revD); } } }
private void ChangeTriRecent() { if (!_isTriRecent) { ReviewsD = new ObservableCollection <ReviewDisplay>(ReviewsD.OrderByDescending(rev => rev.DatePublication)); _isTriRecent = !_isTriRecent; SourceImageButtonTriRecent = "@drawable/arrow_up.png"; SourceImageButtonTriAncien = "@drawable/arrow_down_gray.png"; } }