public void Dispose() { CanEditCompletion?.Dispose(); MylistName?.Dispose(); MylistDescription?.Dispose(); MylistIsPublicIndex?.Dispose(); SelectedSort?.Dispose(); LastErrorMessage?.Dispose(); }
private int ItemGridSort(UIElement x, UIElement y) { UIItemCatalogueItemSlot a = x as UIItemCatalogueItemSlot; UIItemCatalogueItemSlot b = y as UIItemCatalogueItemSlot; if (SelectedSort != null) { return(SelectedSort.sort(a.item, b.item)); } return(a.itemType.CompareTo(b.itemType)); }
private IEnumerable <TrinityActor> ApplySort(IQueryable <TrinityActor> collection) { var sortProp = SelectedSort.ToString(); if (sortProp == "None" || sortProp == "All") { sortProp = "Weight"; } return(OrderByField(collection, sortProp, SortDirection == SortDirection.Ascending)); }
public void Refresh() { if (SelectedSort.Contains("Name")) { SortByName(); } else if (SelectedSort.Contains("City")) { SortByCity(); } else { _JobsList = RFRepo.GetJobs(SelectedStatus); RaisePropertyChanged("JobsList"); } }
void AddPredicate(ComboBox sort_var) { string predicate = string.Empty; if (sort_var.SelectedValue != null && sort_var.SelectedValue is string && ((string)sort_var.SelectedValue) != "") { string value = sort_var.SelectedValue.ToString(); int aggregateKey; if (int.TryParse(value, out aggregateKey)) { predicate = DataHelper.BoundaryAggregation[aggregateKey].ObjectResolution; } else { predicate = value; } SelectedSort.Add(predicate); SelectedSortKeys.Add(value); } }