示例#1
0
 private void ValidateTopFavorited()
 {
     if (chkTopFavorites.IsChecked.Value)
     {
         if (FavTime.SelectedItem != null)
         {
             InnerTubeTime time = (InnerTubeTime)Enum.Parse(typeof(InnerTubeTime), FavTime.SelectedItem.ToString());
             string        url  = InnerTubeService.BuildTimeUrl(InnerTubeService.TopFavoritesUrl, time);
             AddFeed("Top Favorited " + time.ToString(), url);
         }
         else
         {
             AddFeed("Top Favorited ", InnerTubeService.TopFavoritesUrl);
         }
     }
 }
示例#2
0
        private void ValidateMostViewed()
        {
            if (chkMostViewed.IsChecked.Value)
            {
                if (ViewTime.SelectedItem != null)
                {
                    //Add MostViewed by time
                    InnerTubeTime time = (InnerTubeTime)Enum.Parse(typeof(InnerTubeTime), ViewTime.SelectedItem.ToString());

                    string url = InnerTubeService.BuildTimeUrl(InnerTubeService.MostViewedUrl, time);

                    AddFeed("Most Viewed " + time.ToString(), url);
                }
                else
                {
                    AddFeed("Most Viewed ", InnerTubeService.MostViewedUrl);
                }
            }
        }