Ejemplo n.º 1
0
 public void AddPlaylistToQueue(AV type)
 {
     if (CurrentPlaylistID != "")
     {
         Search search = new Search(CurrentPlaylistID, Search.SearchType.PlaylistVideos);
         List<string> url = search.GetUrl();
         List<string> title = search.GetTitle();
         List<string> views = search.GetViews();
         List<string> length = search.GetLength();
         for (int i = 0; i < url.Count; i++)
         {
             if (!QueueContains(title[i], type))
                 AddToQueue(title[i], url[i], views[i], length[i], type);
         }
     }
 }
Ejemplo n.º 2
0
 public void AddPlaylistToQueue(AV type)
 {
     if (CurrentPlaylistID != "")
     {
         Search search = new Search(CurrentPlaylistID, Search.SearchType.PlaylistVideos);
         List<string> url = search.GetUrl();
         List<string> title = search.GetTitle();
         List<string> views = search.GetViews();
         List<string> length = search.GetLength();
         if (CurrentPlaylistVideoB64URL == "")
         {
             for (int i = 1; i < url.Count; i++)
             {
                 if (!QueueContains(title[i], type))
                     AddToQueue(title[i], url[i], views[i], length[i], type);
             }
         }
         else
         {
             int i = lv_pvdata.SelectedIndices[0];
             if (QueueContains(lv_pvdata.Items[i].Text, type))
             {
                 MessageBox.Show("You are already downloading a video of the same name!", "Whoops :P");
             }
             else
             {
                 AddToQueue(lv_pvdata.Items[i].Text, IDsPlaylistVideo[i], lv_pvdata.Items[i].SubItems[1].Text,
                     lv_pvdata.Items[i].SubItems[2].Text, type);
             }
         }
     }
 }