public void Load() { var appOrders = getPrefs().GetStringSet("prefsAppOrder", new List <string> ()).ToList(); var ordering = new List <AppOrder> (); foreach (var s in appOrders) { var parts = s.Split(new char [] { '|' }, 2); if (parts.Length == 2) { int order = 0; if (int.TryParse(parts [0], out order)) { ordering.Add(new AppOrder { Order = order, PackageName = parts [1] }); } } } ordering.Sort((o1, o2) => o1.Order.CompareTo(o2.Order)); lock (orderingLockObj) { Ordering.Clear(); Ordering.AddRange(ordering); } }
public void Load() { var appOrders = getPrefs().GetStringSet("prefsAppOrder", new List <string> ()).ToList(); var ordering = new List <AppOrder> (); foreach (var s in appOrders) { var parts = s.Split(new char [] { '|' }, 2); if (parts.Length == 2) { int order = 0; if (int.TryParse(parts [0], out order)) { ordering.Add(new AppOrder { Order = order, PackageName = parts [1] }); } } } ordering.Sort((o1, o2) => o1.Order.CompareTo(o2.Order)); lock (orderingLockObj) { Ordering.Clear(); Ordering.AddRange(ordering); } Blacklist = getPrefs().GetStringSet("prefsBlacklist", new List <string> { "com.altusapps.firedtvlauncher", "com.amazon.avod", "com.amazon.bueller.photos", "com.amazon.device.bluetoothdfu", "com.amazon.device.gmo", "com.amazon.venezia", "com.amazon.storm.lightning.tutorial", "com.broadcom.wfd.client", "com.amazon.cpl", }).ToList(); }