private static int ComparePassengers(UIComponent left, UIComponent right) { TLMLineListItem <T> component = left.GetComponent <TLMLineListItem <T> >(); TLMLineListItem <T> component2 = right.GetComponent <TLMLineListItem <T> >(); return(component2.passengerCountsInt.CompareTo(component.passengerCountsInt)); }
private static int CompareVehicles(UIComponent left, UIComponent right) { TLMLineListItem <T> component = left.GetComponent <TLMLineListItem <T> >(); TLMLineListItem <T> component2 = right.GetComponent <TLMLineListItem <T> >(); return(NaturalCompare(component2.vehicleCounts, component.vehicleCounts)); }
private static int CompareNames(UIComponent left, UIComponent right) { TLMLineListItem <T> component = left.GetComponent <TLMLineListItem <T> >(); TLMLineListItem <T> component2 = right.GetComponent <TLMLineListItem <T> >(); return(string.Compare(component.lineName, component2.lineName, StringComparison.InvariantCulture)); }
private void toggleAllLinesVisibility(UIComponent component, bool value) { foreach (var item in mainPanel.components) { TLMLineListItem <T> comp = (TLMLineListItem <T>)item.GetComponent(ImplClassChildren); comp.ChangeLineVisibility(value); } isUpdated = false; }
private static int CompareLineNumbers(UIComponent left, UIComponent right) { if (left == null || right == null) { return(0); } TLMLineListItem <T> component = left.GetComponent <TLMLineListItem <T> >(); TLMLineListItem <T> component2 = right.GetComponent <TLMLineListItem <T> >(); if (component == null || component2 == null) { return(0); } return(component.lineNumber.CompareTo(component2.lineNumber)); }