예제 #1
0
 public static void Play(MediaItem item)
 {
     Services.Application.RunOnThread(() => bus.Play(LoadMedia(item)));
 }
예제 #2
0
 public static void Enqueue(MediaItem item)
 {
     Services.Application.RunOnThread(() => bus.Enqueue(LoadMedia(item)));
 }
예제 #3
0
 static bool ContainsMatch(MediaItem item, Func <PropertyInfo, bool> predicate)
 {
     return(item.GetType().GetProperties().Any(predicate));
 }
예제 #4
0
 static bool PropertyInfoMatchesPattern(MediaItem item, PropertyInfo info, string pattern)
 {
     return(info.Name != "File" && (info.GetValue(item, null).ToString().Contains(pattern)));
 }
예제 #5
0
 static bool ContainsMatch(MediaItem item, string pattern)
 {
     return(ContainsMatch(item, p => PropertyInfoMatchesPattern(item, p, pattern)));
 }