public void RemoveSubreddit(Subreddit subreddit) { Subreddits.Remove(subreddit); SaveSubreddits(); if(subreddit.FriendlyName == GalleryTitle) { LoadGallery(); } }
public async void LoadSubreddit(Subreddit subreddit) { ImageItems = new ObservableCollection<GalleryItem>(); GalleryTitle = subreddit.FriendlyName; var subredditGallery = await Gallery.GetSubreddditGallery(subreddit.Name); foreach (var image in subredditGallery) { ImageItems.Add(new GalleryItem(image)); } }
public void AddSubreddit(Subreddit subreddit) { Subreddits.Insert(0, subreddit); SaveSubreddits(); }