public NicoFavoriteViewModel() { AddLoadTask(() => { Mylists = NicoUtil.Favorites.ToSyncedSynchronizationContextCollection( x => new NicoMylistViewModel(x.MylistId), System.Threading.SynchronizationContext.Current ); }); Disposed += (sender, e) => { Mylists.ForEach(x => x.Dispose()); Mylists.ClearOnUI(); }; }
public async Task <SearchVideoByMylistModel> GetMylist(string id) { var mylist = Mylists.FirstOrDefault(v => v.MylistId == id); if (mylist == null) { mylist = new SearchVideoByMylistModel(id) { MylistId = id }; await mylist.Reload(); Mylists.Add(mylist); } return(mylist); }
public LoginUserMylistPlaylist GetMylistGroup(string groupId) { return(Mylists.SingleOrDefault(x => x.Id == groupId)); }
public bool HasMylistGroup(string groupId) { return(Mylists.Any(x => x.Id == groupId)); }
public bool CheckIsRegistratedAnyMylist(string videoId) { return(Mylists.Any(x => x.ContainsVideoId(videoId))); }
public UserOwnedMylist GetMylistGroup(string groupId) { return(Mylists.SingleOrDefault(x => x.GroupId == groupId)); }