RadioDld.Main.ButtonDownload_Click C# (CSharp) Method

ButtonDownload_Click() private method

private ButtonDownload_Click ( ) : void
return void
        private void ButtonDownload_Click()
        {
            List<int> epids = new List<int>();

            foreach (ListViewItem item in this.ListEpisodes.SelectedItems)
            {
                epids.Add(Convert.ToInt32(item.Name, CultureInfo.InvariantCulture));
            }

            // Add the items in date order, oldest first
            epids.Reverse();

            if (Model.Download.Add(epids.ToArray()))
            {
                this.view.SetView(ViewState.MainTab.Downloads, ViewState.View.Downloads);
            }
            else
            {
                string episodes;

                if (epids.Count == 1)
                {
                    episodes = "The selected episode is";
                }
                else
                {
                    episodes = "All of the selected episodes are";
                }

                MessageBox.Show(episodes + " already in your downloads list.", Application.ProductName);
            }
        }
Main