Vereinsmeisterschaften  22aa7800eae54b428d40e835886cefe1fdefdfdf
This is a software that can be used to manage the internal competition of the swimming club Illertissen called "Vereinsmeisterschaften".
Loading...
Searching...
No Matches
CollectionHelper.cs
1using System.Collections.ObjectModel;
2
4{
8 public static class CollectionHelper
9 {
17 public static void Sort<T>(this ObservableCollection<T> collection, Comparison<T> comparison)
18 {
19 var sortableList = new List<T>(collection);
20 sortableList.Sort(comparison);
21
22 for (int i = 0; i < sortableList.Count; i++)
23 {
24 collection.Move(collection.IndexOf(sortableList[i]), i);
25 }
26 }
27 }
28}