Index: RadioEpgGrabber.cs
===================================================================
--- RadioEpgGrabber.cs	(Revision 27464)
+++ RadioEpgGrabber.cs	(Arbeitskopie)
@@ -24,6 +24,7 @@
 using TvControl;
 using Gentle.Framework;
 using TvDatabase;
+using TvLibrary.Log;
 using TvLibrary.Interfaces;
 using MediaPortal.UserInterface.Controls;
 
@@ -35,7 +36,7 @@
     private readonly MPListViewStringColumnSorter lvwColumnSorter;
 
     public RadioEpgGrabber()
-      : this("Radio Epg grabber") {}
+      : this("Radio Epg grabber") { }
 
     public RadioEpgGrabber(string name)
       : base(name)
@@ -46,7 +47,6 @@
       mpListView1.ListViewItemSorter = lvwColumnSorter;
     }
 
-
     private void LoadLanguages()
     {
       _loaded = true;
@@ -59,12 +59,11 @@
         List<String> list = languages.GetLanguages();
 
         TvBusinessLayer layer = new TvBusinessLayer();
-        Setting setting = layer.GetSetting("radioLanguages");
-
+        Setting setting = layer.GetSetting("epgRadioLanguages");
         string values = "";
         for (int j = 0; j < list.Count; j++)
         {
-          ListViewItem item = new ListViewItem(new string[] {list[j], codes[j]});
+          ListViewItem item = new ListViewItem(new string[] { list[j], codes[j] });
           mpListView2.Items.Add(item);
           item.Tag = codes[j];
           if (setting.Value == "")
@@ -81,7 +80,6 @@
           }
         }
         mpListView2.Sort();
-
         if (setting.Value == "")
         {
           setting.Value = values;
@@ -97,18 +95,25 @@
 
     public override void OnSectionDeActivated()
     {
+      TvBusinessLayer layer = new TvBusinessLayer();
+      Setting setting = layer.GetSetting("epgRadioStoreOnlySelected");
+      setting.Value = mpCheckBoxStoreOnlySelected.Checked ? "yes" : "no";
+      setting.Persist();
+      base.OnSectionDeActivated();
       SaveSettings();
-      base.OnSectionDeActivated();
     }
 
     public override void OnSectionActivated()
     {
-     
 
+
       mpListView1.BeginUpdate();
       try
       {
         LoadLanguages();
+        TvBusinessLayer layer = new TvBusinessLayer();
+        Setting setting = layer.GetSetting("epgRadioStoreOnlySelected");
+        mpCheckBoxStoreOnlySelected.Checked = (setting.Value == "yes");
         Dictionary<string, CardType> cards = new Dictionary<string, CardType>();
         IList<Card> dbsCards = Card.ListAll();
         foreach (Card card in dbsCards)
@@ -117,12 +122,10 @@
         }
         base.OnSectionActivated();
         mpListView1.Items.Clear();
-
-        SqlBuilder sb = new SqlBuilder(StatementType.Select, typeof (Channel));
+        SqlBuilder sb = new SqlBuilder(StatementType.Select, typeof(Channel));
         sb.AddOrderByField(true, "sortOrder");
         SqlStatement stmt = sb.GetStatement(true);
         IList<Channel> channels = ObjectFactory.GetCollection<Channel>(stmt.Execute());
-
         foreach (Channel ch in channels)
         {
           bool analog = false;
@@ -131,13 +134,12 @@
           bool dvbs = false;
           bool atsc = false;
           bool dvbip = false;
+          bool hasFta = false;
+          bool hasScrambled = false;
           if (ch.IsRadio == false)
             continue;
           if (ch.IsWebstream())
             continue;
-
-          bool hasFta = false;
-          bool hasScrambled = false;
           IList<TuningDetail> tuningDetails = ch.ReferringTuningDetail();
           foreach (TuningDetail detail in tuningDetails)
           {
@@ -149,9 +151,7 @@
             {
               hasScrambled = true;
             }
-
           }
-
           int imageIndex;
           if (hasFta && hasScrambled)
           {
@@ -165,7 +165,6 @@
           {
             imageIndex = 0;
           }
-
           ListViewItem item = mpListView1.Items.Add(ch.DisplayName, imageIndex);
           foreach (ChannelMap map in ch.ReferringChannelMap())
           {
@@ -226,7 +225,8 @@
           }
           if (dvbip)
           {
-            if (line != "") line += ",";
+            if (line != "")
+              line += ",";
             line += "DVB-IP";
           }
           item.SubItems.Add(line);
@@ -240,6 +240,45 @@
       }
     }
 
+    public override void SaveSettings()
+    {
+      if (false == _loaded)
+        return;
+      TvBusinessLayer layer = new TvBusinessLayer();
+      Setting setting = layer.GetSetting("epgRadioLanguages");
+      setting.Value = ",";
+      for (int i = 0; i < mpListView2.Items.Count; ++i)
+      {
+        if (mpListView2.Items[i].Checked)
+        {
+          string code = (string)mpListView2.Items[i].Tag;
+          setting.Value += code;
+          setting.Value += ",";
+        }
+      }
+      setting.Persist();
+      base.SaveSettings();
+    }
+
+    private void mpListView1_ColumnClick(object sender, ColumnClickEventArgs e)
+    {
+      if (e.Column == lvwColumnSorter.SortColumn)
+      {
+        // Reverse the current sort direction for this column.
+        lvwColumnSorter.Order = lvwColumnSorter.Order == SortOrder.Ascending
+                                  ? SortOrder.Descending
+                                  : SortOrder.Ascending;
+      }
+      else
+      {
+        // Set the column number that is to be sorted; default to ascending.
+        lvwColumnSorter.SortColumn = e.Column;
+        lvwColumnSorter.Order = SortOrder.Ascending;
+      }
+      // Perform the sort with these new sort options.
+      mpListView1.Sort();
+    }
+
     private void mpListView1_ItemChecked(object sender, ItemCheckedEventArgs e)
     {
       Channel channel = e.Item.Tag as Channel;
@@ -249,25 +288,15 @@
       channel.Persist();
     }
 
-    private void mpButtonAll_Click(object sender, EventArgs e)
+    private void linkLabelRadioAll_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
       mpListView1.BeginUpdate();
       try
       {
-        for (int i = 0; i < mpListView2.Items.Count; ++i)
+        for (int i = 0; i < mpListView1.Items.Count; ++i)
         {
-          mpListView2.Items[i].Checked = true;
+          mpListView1.Items[i].Checked = true;
         }
-        TvLibrary.Epg.Languages languages = new TvLibrary.Epg.Languages();
-        List<String> codes = languages.GetLanguageCodes();
-        TvBusinessLayer layer = new TvBusinessLayer();
-        Setting setting = layer.GetSetting("radioLanguages");
-        setting.Value = "";
-        foreach (string code in codes)
-        {
-          setting.Value += code;
-          setting.Value += ",";
-        }
       }
       finally
       {
@@ -275,7 +304,7 @@
       }
     }
 
-    private void mpButtonAllGrouped_Click(object sender, EventArgs e)
+    private void linkLabelRadioAllGrouped_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
       mpListView1.BeginUpdate();
       try
@@ -293,19 +322,17 @@
       }
     }
 
-    private void mpButtonNone_Click(object sender, EventArgs e)
+    private void linkLabelRadioGroupedVisible_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
       mpListView1.BeginUpdate();
       try
       {
-        for (int i = 0; i < mpListView2.Items.Count; ++i)
+        for (int i = 0; i < mpListView1.Items.Count; ++i)
         {
-          mpListView2.Items[i].Checked = false;
+          Channel ch = (Channel)mpListView1.Items[i].Tag;
+          mpListView1.Items[i].Checked = (ch.ReferringRadioGroupMap().Count > 1 && ch.VisibleInGuide);
+          // if count > 1 we assume that the channel has one or more custom group(s) associated with it.
         }
-        TvBusinessLayer layer = new TvBusinessLayer();
-        Setting setting = layer.GetSetting("radioLanguages");
-        setting.Value = ",";
-        setting.Persist();
       }
       finally
       {
@@ -313,35 +340,14 @@
       }
     }
 
-
-    public override void SaveSettings()
+    private void linkLabelRadioNone_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
-      if (false == _loaded)
-        return;
-      TvBusinessLayer layer = new TvBusinessLayer();
-      Setting setting = layer.GetSetting("radioLanguages");
-      setting.Value = ",";
-      for (int i = 0; i < mpListView2.Items.Count; ++i)
-      {
-        if (mpListView2.Items[i].Checked)
-        {
-          string code = (string)mpListView2.Items[i].Tag;
-          setting.Value += code;
-          setting.Value += ",";
-        }
-      }
-      setting.Persist();
-      base.SaveSettings();
-    }
-
-    private void mpButtonAllChannels_Click(object sender, EventArgs e)
-    {
       mpListView1.BeginUpdate();
       try
       {
         for (int i = 0; i < mpListView1.Items.Count; ++i)
         {
-          mpListView1.Items[i].Checked = true;
+          mpListView1.Items[i].Checked = false;
         }
       }
       finally
@@ -350,40 +356,53 @@
       }
     }
 
-    private void mpButtonClearChannels_Click(object sender, EventArgs e)
+    private void linkLabelLanguageAll_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
-      mpListView1.BeginUpdate();
+      mpListView2.BeginUpdate();
       try
       {
-        for (int i = 0; i < mpListView1.Items.Count; ++i)
+        for (int i = 0; i < mpListView2.Items.Count; ++i)
         {
-          mpListView1.Items[i].Checked = false;
+          mpListView2.Items[i].Checked = true;
         }
+        TvLibrary.Epg.Languages languages = new TvLibrary.Epg.Languages();
+        List<String> codes = languages.GetLanguageCodes();
+        TvBusinessLayer layer = new TvBusinessLayer();
+        Setting setting = layer.GetSetting("epgRadioLanguages");
+        setting.Value = "";
+        foreach (string code in codes)
+        {
+          setting.Value += code;
+          setting.Value += ",";
+        }
+        //Log.WriteFile("tvsetup:epggrabber:all: epglang={0}", setting.Value);
+        setting.Persist();
       }
       finally
       {
-        mpListView1.EndUpdate();
+        mpListView2.EndUpdate();
       }
     }
 
-    private void mpListView1_ColumnClick(object sender, ColumnClickEventArgs e)
+    private void linkLabelLanguageNone_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
-      if (e.Column == lvwColumnSorter.SortColumn)
+      mpListView2.BeginUpdate();
+      try
       {
-        // Reverse the current sort direction for this column.
-        lvwColumnSorter.Order = lvwColumnSorter.Order == SortOrder.Ascending
-                                  ? SortOrder.Descending
-                                  : SortOrder.Ascending;
+        for (int i = 0; i < mpListView2.Items.Count; ++i)
+        {
+          mpListView2.Items[i].Checked = false;
+        }
+        TvBusinessLayer layer = new TvBusinessLayer();
+        Setting setting = layer.GetSetting("epgRadioLanguages");
+        setting.Value = ",";
+        Log.WriteFile("tvsetup:epggrabber:none: epglang={0}", setting.Value);
+        setting.Persist();
       }
-      else
+      finally
       {
-        // Set the column number that is to be sorted; default to ascending.
-        lvwColumnSorter.SortColumn = e.Column;
-        lvwColumnSorter.Order = SortOrder.Ascending;
+        mpListView2.EndUpdate();
       }
-
-      // Perform the sort with these new sort options.
-      mpListView1.Sort();
     }
   }
 }
\ No newline at end of file
Index: RadioEpgGrabber.Designer.cs
===================================================================
--- RadioEpgGrabber.Designer.cs	(Revision 27464)
+++ RadioEpgGrabber.Designer.cs	(Arbeitskopie)
@@ -30,77 +30,67 @@
     {
       this.components = new System.ComponentModel.Container();
       System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(RadioEpgGrabber));
+      this.mpCheckBoxStoreOnlySelected = new MediaPortal.UserInterface.Controls.MPCheckBox();
+      this.columnHeader4 = new System.Windows.Forms.ColumnHeader();
+      this.mpLabelChannelCount = new MediaPortal.UserInterface.Controls.MPLabel();
+      this.mpLabel1 = new MediaPortal.UserInterface.Controls.MPLabel();
+      this.columnHeader2 = new System.Windows.Forms.ColumnHeader();
+      this.mpListView2 = new MediaPortal.UserInterface.Controls.MPListView();
+      this.tabControl1 = new System.Windows.Forms.TabControl();
+      this.tabPage1 = new System.Windows.Forms.TabPage();
+      this.linkLabelLanguageNone = new System.Windows.Forms.LinkLabel();
+      this.linkLabelLanguageAll = new System.Windows.Forms.LinkLabel();
+      this.linkLabelRadioNone = new System.Windows.Forms.LinkLabel();
+      this.linkLabelRadioGroupedVisible = new System.Windows.Forms.LinkLabel();
+      this.linkLabelRadioAllGrouped = new System.Windows.Forms.LinkLabel();
+      this.linkLabelRadioAll = new System.Windows.Forms.LinkLabel();
       this.mpListView1 = new MediaPortal.UserInterface.Controls.MPListView();
       this.columnHeader1 = new System.Windows.Forms.ColumnHeader();
       this.columnHeader3 = new System.Windows.Forms.ColumnHeader();
       this.imageList1 = new System.Windows.Forms.ImageList(this.components);
-      this.mpLabel1 = new MediaPortal.UserInterface.Controls.MPLabel();
-      this.mpListView2 = new MediaPortal.UserInterface.Controls.MPListView();
-      this.columnHeader2 = new System.Windows.Forms.ColumnHeader();
-      this.columnHeader4 = new System.Windows.Forms.ColumnHeader();
       this.mpLabel2 = new MediaPortal.UserInterface.Controls.MPLabel();
-      this.mpButtonAll = new MediaPortal.UserInterface.Controls.MPButton();
-      this.mpButtonNone = new MediaPortal.UserInterface.Controls.MPButton();
-      this.mpButtonClearChannels = new MediaPortal.UserInterface.Controls.MPButton();
-      this.mpButtonAllChannels = new MediaPortal.UserInterface.Controls.MPButton();
-      this.tabControl1 = new System.Windows.Forms.TabControl();
-      this.tabPage1 = new System.Windows.Forms.TabPage();
-      this.mpButtonAllGrouped = new MediaPortal.UserInterface.Controls.MPButton();
-      this.mpLabelChannelCount = new MediaPortal.UserInterface.Controls.MPLabel();
       this.tabControl1.SuspendLayout();
       this.tabPage1.SuspendLayout();
       this.SuspendLayout();
       // 
-      // mpListView1
+      // mpCheckBoxStoreOnlySelected
       // 
-      this.mpListView1.AllowDrop = true;
-      this.mpListView1.AllowRowReorder = true;
-      this.mpListView1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
-                  | System.Windows.Forms.AnchorStyles.Left)));
-      this.mpListView1.CheckBoxes = true;
-      this.mpListView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
-            this.columnHeader1,
-            this.columnHeader3});
-      this.mpListView1.FullRowSelect = true;
-      this.mpListView1.LargeImageList = this.imageList1;
-      this.mpListView1.Location = new System.Drawing.Point(6, 29);
-      this.mpListView1.Name = "mpListView1";
-      this.mpListView1.Size = new System.Drawing.Size(208, 297);
-      this.mpListView1.SmallImageList = this.imageList1;
-      this.mpListView1.TabIndex = 1;
-      this.mpListView1.UseCompatibleStateImageBehavior = false;
-      this.mpListView1.View = System.Windows.Forms.View.Details;
-      this.mpListView1.ItemChecked += new System.Windows.Forms.ItemCheckedEventHandler(this.mpListView1_ItemChecked);
-      this.mpListView1.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.mpListView1_ColumnClick);
+      this.mpCheckBoxStoreOnlySelected.AutoSize = true;
+      this.mpCheckBoxStoreOnlySelected.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+      this.mpCheckBoxStoreOnlySelected.Location = new System.Drawing.Point(10, 6);
+      this.mpCheckBoxStoreOnlySelected.Name = "mpCheckBoxStoreOnlySelected";
+      this.mpCheckBoxStoreOnlySelected.Size = new System.Drawing.Size(199, 17);
+      this.mpCheckBoxStoreOnlySelected.TabIndex = 20;
+      this.mpCheckBoxStoreOnlySelected.Text = "Store data only for selected channels";
+      this.mpCheckBoxStoreOnlySelected.UseVisualStyleBackColor = true;
       // 
-      // columnHeader1
+      // columnHeader4
       // 
-      this.columnHeader1.Text = "Name";
-      this.columnHeader1.Width = 125;
+      this.columnHeader4.Text = "ID";
+      this.columnHeader4.Width = 36;
       // 
-      // columnHeader3
+      // mpLabelChannelCount
       // 
-      this.columnHeader3.Text = "Types";
-      this.columnHeader3.Width = 61;
+      this.mpLabelChannelCount.AutoSize = true;
+      this.mpLabelChannelCount.Location = new System.Drawing.Point(13, 14);
+      this.mpLabelChannelCount.Name = "mpLabelChannelCount";
+      this.mpLabelChannelCount.Size = new System.Drawing.Size(0, 13);
+      this.mpLabelChannelCount.TabIndex = 2;
       // 
-      // imageList1
-      // 
-      this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
-      this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
-      this.imageList1.Images.SetKeyName(0, "radio_scrambled.png");
-      this.imageList1.Images.SetKeyName(1, "tv_fta_.png");
-      this.imageList1.Images.SetKeyName(2, "tv_scrambled.png");
-      this.imageList1.Images.SetKeyName(3, "radio_fta_.png");
-      // 
       // mpLabel1
       // 
       this.mpLabel1.AutoSize = true;
-      this.mpLabel1.Location = new System.Drawing.Point(6, 13);
+      this.mpLabel1.Location = new System.Drawing.Point(7, 33);
       this.mpLabel1.Name = "mpLabel1";
       this.mpLabel1.Size = new System.Drawing.Size(148, 13);
       this.mpLabel1.TabIndex = 2;
       this.mpLabel1.Text = "Grab EPG for these channels:";
       // 
+      // columnHeader2
+      // 
+      this.columnHeader2.Text = "Language";
+      this.columnHeader2.Width = 152;
+      // 
       // mpListView2
       // 
       this.mpListView2.AllowDrop = true;
@@ -112,134 +102,173 @@
       this.mpListView2.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
             this.columnHeader2,
             this.columnHeader4});
-      this.mpListView2.Location = new System.Drawing.Point(236, 29);
+      this.mpListView2.IsChannelListView = false;
+      this.mpListView2.Location = new System.Drawing.Point(254, 51);
       this.mpListView2.Name = "mpListView2";
-      this.mpListView2.Size = new System.Drawing.Size(205, 297);
+      this.mpListView2.Size = new System.Drawing.Size(217, 312);
       this.mpListView2.TabIndex = 3;
       this.mpListView2.UseCompatibleStateImageBehavior = false;
       this.mpListView2.View = System.Windows.Forms.View.Details;
       // 
-      // columnHeader2
-      // 
-      this.columnHeader2.Text = "Language";
-      this.columnHeader2.Width = 165;
-      // 
-      // columnHeader4
-      // 
-      this.columnHeader4.Text = "ID";
-      this.columnHeader4.Width = 39;
-      // 
-      // mpLabel2
-      // 
-      this.mpLabel2.AutoSize = true;
-      this.mpLabel2.Location = new System.Drawing.Point(233, 13);
-      this.mpLabel2.Name = "mpLabel2";
-      this.mpLabel2.Size = new System.Drawing.Size(187, 13);
-      this.mpLabel2.TabIndex = 4;
-      this.mpLabel2.Text = "Grab EPG for the following languages:";
-      // 
-      // mpButtonAll
-      // 
-      this.mpButtonAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
-      this.mpButtonAll.Location = new System.Drawing.Point(285, 341);
-      this.mpButtonAll.Name = "mpButtonAll";
-      this.mpButtonAll.Size = new System.Drawing.Size(75, 23);
-      this.mpButtonAll.TabIndex = 5;
-      this.mpButtonAll.Text = "All";
-      this.mpButtonAll.UseVisualStyleBackColor = true;
-      this.mpButtonAll.Click += new System.EventHandler(this.mpButtonAll_Click);
-      // 
-      // mpButtonNone
-      // 
-      this.mpButtonNone.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
-      this.mpButtonNone.Location = new System.Drawing.Point(366, 341);
-      this.mpButtonNone.Name = "mpButtonNone";
-      this.mpButtonNone.Size = new System.Drawing.Size(75, 23);
-      this.mpButtonNone.TabIndex = 6;
-      this.mpButtonNone.Text = "None";
-      this.mpButtonNone.UseVisualStyleBackColor = true;
-      this.mpButtonNone.Click += new System.EventHandler(this.mpButtonNone_Click);
-      // 
-      // mpButtonClearChannels
-      // 
-      this.mpButtonClearChannels.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-      this.mpButtonClearChannels.Location = new System.Drawing.Point(161, 341);
-      this.mpButtonClearChannels.Name = "mpButtonClearChannels";
-      this.mpButtonClearChannels.Size = new System.Drawing.Size(53, 23);
-      this.mpButtonClearChannels.TabIndex = 8;
-      this.mpButtonClearChannels.Text = "None";
-      this.mpButtonClearChannels.UseVisualStyleBackColor = true;
-      this.mpButtonClearChannels.Click += new System.EventHandler(this.mpButtonClearChannels_Click);
-      // 
-      // mpButtonAllChannels
-      // 
-      this.mpButtonAllChannels.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-      this.mpButtonAllChannels.Location = new System.Drawing.Point(6, 341);
-      this.mpButtonAllChannels.Name = "mpButtonAllChannels";
-      this.mpButtonAllChannels.Size = new System.Drawing.Size(56, 23);
-      this.mpButtonAllChannels.TabIndex = 7;
-      this.mpButtonAllChannels.Text = "All";
-      this.mpButtonAllChannels.UseVisualStyleBackColor = true;
-      this.mpButtonAllChannels.Click += new System.EventHandler(this.mpButtonAllChannels_Click);
-      // 
       // tabControl1
       // 
       this.tabControl1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
                   | System.Windows.Forms.AnchorStyles.Left)
                   | System.Windows.Forms.AnchorStyles.Right)));
       this.tabControl1.Controls.Add(this.tabPage1);
-      this.tabControl1.Location = new System.Drawing.Point(1, 3);
+      this.tabControl1.ItemSize = new System.Drawing.Size(87, 18);
+      this.tabControl1.Location = new System.Drawing.Point(3, 3);
       this.tabControl1.Name = "tabControl1";
       this.tabControl1.SelectedIndex = 0;
-      this.tabControl1.Size = new System.Drawing.Size(460, 398);
-      this.tabControl1.TabIndex = 10;
+      this.tabControl1.Size = new System.Drawing.Size(485, 431);
+      this.tabControl1.TabIndex = 11;
       // 
       // tabPage1
       // 
-      this.tabPage1.Controls.Add(this.mpButtonAllGrouped);
+      this.tabPage1.Controls.Add(this.linkLabelLanguageNone);
+      this.tabPage1.Controls.Add(this.linkLabelLanguageAll);
+      this.tabPage1.Controls.Add(this.linkLabelRadioNone);
+      this.tabPage1.Controls.Add(this.linkLabelRadioGroupedVisible);
+      this.tabPage1.Controls.Add(this.linkLabelRadioAllGrouped);
+      this.tabPage1.Controls.Add(this.linkLabelRadioAll);
+      this.tabPage1.Controls.Add(this.mpCheckBoxStoreOnlySelected);
       this.tabPage1.Controls.Add(this.mpLabelChannelCount);
-      this.tabPage1.Controls.Add(this.mpButtonClearChannels);
       this.tabPage1.Controls.Add(this.mpLabel1);
-      this.tabPage1.Controls.Add(this.mpButtonAllChannels);
       this.tabPage1.Controls.Add(this.mpListView1);
-      this.tabPage1.Controls.Add(this.mpButtonNone);
       this.tabPage1.Controls.Add(this.mpListView2);
-      this.tabPage1.Controls.Add(this.mpButtonAll);
       this.tabPage1.Controls.Add(this.mpLabel2);
       this.tabPage1.Location = new System.Drawing.Point(4, 22);
       this.tabPage1.Name = "tabPage1";
       this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
-      this.tabPage1.Size = new System.Drawing.Size(452, 372);
+      this.tabPage1.Size = new System.Drawing.Size(477, 405);
       this.tabPage1.TabIndex = 0;
       this.tabPage1.Text = "Radio EPG grabber";
       this.tabPage1.UseVisualStyleBackColor = true;
       // 
-      // mpButtonAllGrouped
+      // linkLabelLanguageNone
       // 
-      this.mpButtonAllGrouped.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-      this.mpButtonAllGrouped.Location = new System.Drawing.Point(75, 341);
-      this.mpButtonAllGrouped.Name = "mpButtonAllGrouped";
-      this.mpButtonAllGrouped.Size = new System.Drawing.Size(75, 23);
-      this.mpButtonAllGrouped.TabIndex = 19;
-      this.mpButtonAllGrouped.Text = "All grouped";
-      this.mpButtonAllGrouped.UseVisualStyleBackColor = true;
-      this.mpButtonAllGrouped.Click += new System.EventHandler(this.mpButtonAllGrouped_Click);
+      this.linkLabelLanguageNone.AutoSize = true;
+      this.linkLabelLanguageNone.Location = new System.Drawing.Point(280, 376);
+      this.linkLabelLanguageNone.Name = "linkLabelLanguageNone";
+      this.linkLabelLanguageNone.Size = new System.Drawing.Size(33, 13);
+      this.linkLabelLanguageNone.TabIndex = 30;
+      this.linkLabelLanguageNone.TabStop = true;
+      this.linkLabelLanguageNone.Text = "None";
+      this.linkLabelLanguageNone.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelLanguageNone_LinkClicked);
       // 
-      // mpLabelChannelCount
+      // linkLabelLanguageAll
       // 
-      this.mpLabelChannelCount.AutoSize = true;
-      this.mpLabelChannelCount.Location = new System.Drawing.Point(13, 14);
-      this.mpLabelChannelCount.Name = "mpLabelChannelCount";
-      this.mpLabelChannelCount.Size = new System.Drawing.Size(0, 13);
-      this.mpLabelChannelCount.TabIndex = 2;
+      this.linkLabelLanguageAll.AutoSize = true;
+      this.linkLabelLanguageAll.Location = new System.Drawing.Point(256, 376);
+      this.linkLabelLanguageAll.Name = "linkLabelLanguageAll";
+      this.linkLabelLanguageAll.Size = new System.Drawing.Size(18, 13);
+      this.linkLabelLanguageAll.TabIndex = 29;
+      this.linkLabelLanguageAll.TabStop = true;
+      this.linkLabelLanguageAll.Text = "All";
+      this.linkLabelLanguageAll.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelLanguageAll_LinkClicked);
       // 
+      // linkLabelRadioNone
+      // 
+      this.linkLabelRadioNone.AutoSize = true;
+      this.linkLabelRadioNone.Location = new System.Drawing.Point(192, 376);
+      this.linkLabelRadioNone.Name = "linkLabelRadioNone";
+      this.linkLabelRadioNone.Size = new System.Drawing.Size(33, 13);
+      this.linkLabelRadioNone.TabIndex = 28;
+      this.linkLabelRadioNone.TabStop = true;
+      this.linkLabelRadioNone.Text = "None";
+      this.linkLabelRadioNone.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelRadioNone_LinkClicked);
+      // 
+      // linkLabelRadioGroupedVisible
+      // 
+      this.linkLabelRadioGroupedVisible.AutoSize = true;
+      this.linkLabelRadioGroupedVisible.Location = new System.Drawing.Point(96, 376);
+      this.linkLabelRadioGroupedVisible.Name = "linkLabelRadioGroupedVisible";
+      this.linkLabelRadioGroupedVisible.Size = new System.Drawing.Size(90, 13);
+      this.linkLabelRadioGroupedVisible.TabIndex = 27;
+      this.linkLabelRadioGroupedVisible.TabStop = true;
+      this.linkLabelRadioGroupedVisible.Text = "Grouped && Visible";
+      this.linkLabelRadioGroupedVisible.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelRadioGroupedVisible_LinkClicked);
+      // 
+      // linkLabelRadioAllGrouped
+      // 
+      this.linkLabelRadioAllGrouped.AutoSize = true;
+      this.linkLabelRadioAllGrouped.Location = new System.Drawing.Point(32, 376);
+      this.linkLabelRadioAllGrouped.Name = "linkLabelRadioAllGrouped";
+      this.linkLabelRadioAllGrouped.Size = new System.Drawing.Size(62, 13);
+      this.linkLabelRadioAllGrouped.TabIndex = 26;
+      this.linkLabelRadioAllGrouped.TabStop = true;
+      this.linkLabelRadioAllGrouped.Text = "All Grouped";
+      this.linkLabelRadioAllGrouped.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelRadioAllGrouped_LinkClicked);
+      // 
+      // linkLabelRadioAll
+      // 
+      this.linkLabelRadioAll.AutoSize = true;
+      this.linkLabelRadioAll.Location = new System.Drawing.Point(8, 376);
+      this.linkLabelRadioAll.Name = "linkLabelRadioAll";
+      this.linkLabelRadioAll.Size = new System.Drawing.Size(18, 13);
+      this.linkLabelRadioAll.TabIndex = 25;
+      this.linkLabelRadioAll.TabStop = true;
+      this.linkLabelRadioAll.Text = "All";
+      this.linkLabelRadioAll.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelRadioAll_LinkClicked);
+      // 
+      // mpListView1
+      // 
+      this.mpListView1.AllowDrop = true;
+      this.mpListView1.AllowRowReorder = true;
+      this.mpListView1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
+                  | System.Windows.Forms.AnchorStyles.Left)));
+      this.mpListView1.CheckBoxes = true;
+      this.mpListView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
+            this.columnHeader1,
+            this.columnHeader3});
+      this.mpListView1.FullRowSelect = true;
+      this.mpListView1.IsChannelListView = false;
+      this.mpListView1.LargeImageList = this.imageList1;
+      this.mpListView1.Location = new System.Drawing.Point(10, 51);
+      this.mpListView1.Name = "mpListView1";
+      this.mpListView1.Size = new System.Drawing.Size(214, 312);
+      this.mpListView1.SmallImageList = this.imageList1;
+      this.mpListView1.TabIndex = 1;
+      this.mpListView1.UseCompatibleStateImageBehavior = false;
+      this.mpListView1.View = System.Windows.Forms.View.Details;
+      this.mpListView1.ItemChecked += new System.Windows.Forms.ItemCheckedEventHandler(this.mpListView1_ItemChecked);
+      this.mpListView1.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.mpListView1_ColumnClick);
+      // 
+      // columnHeader1
+      // 
+      this.columnHeader1.Text = "Name";
+      this.columnHeader1.Width = 125;
+      // 
+      // columnHeader3
+      // 
+      this.columnHeader3.Text = "Types";
+      this.columnHeader3.Width = 61;
+      // 
+      // imageList1
+      // 
+      this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
+      this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
+      this.imageList1.Images.SetKeyName(0, "radio_scrambled.png");
+      this.imageList1.Images.SetKeyName(1, "tv_fta_.png");
+      this.imageList1.Images.SetKeyName(2, "tv_scrambled.png");
+      this.imageList1.Images.SetKeyName(3, "radio_fta_.png");
+      // 
+      // mpLabel2
+      // 
+      this.mpLabel2.AutoSize = true;
+      this.mpLabel2.Location = new System.Drawing.Point(251, 33);
+      this.mpLabel2.Name = "mpLabel2";
+      this.mpLabel2.Size = new System.Drawing.Size(187, 13);
+      this.mpLabel2.TabIndex = 4;
+      this.mpLabel2.Text = "Grab EPG for the following languages:";
+      // 
       // RadioEpgGrabber
       // 
       this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
       this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
       this.Controls.Add(this.tabControl1);
       this.Name = "RadioEpgGrabber";
-      this.Size = new System.Drawing.Size(463, 404);
+      this.Size = new System.Drawing.Size(491, 437);
       this.tabControl1.ResumeLayout(false);
       this.tabPage1.ResumeLayout(false);
       this.tabPage1.PerformLayout();
@@ -249,23 +278,24 @@
 
     #endregion
 
+    private MediaPortal.UserInterface.Controls.MPCheckBox mpCheckBoxStoreOnlySelected;
+    private System.Windows.Forms.ColumnHeader columnHeader4;
+    private MediaPortal.UserInterface.Controls.MPLabel mpLabelChannelCount;
+    private MediaPortal.UserInterface.Controls.MPLabel mpLabel1;
+    private System.Windows.Forms.ColumnHeader columnHeader2;
+    private MediaPortal.UserInterface.Controls.MPListView mpListView2;
+    private System.Windows.Forms.TabControl tabControl1;
+    private System.Windows.Forms.TabPage tabPage1;
     private MediaPortal.UserInterface.Controls.MPListView mpListView1;
     private System.Windows.Forms.ColumnHeader columnHeader1;
     private System.Windows.Forms.ColumnHeader columnHeader3;
-    private MediaPortal.UserInterface.Controls.MPLabel mpLabel1;
-    private MediaPortal.UserInterface.Controls.MPListView mpListView2;
+    private System.Windows.Forms.ImageList imageList1;
     private MediaPortal.UserInterface.Controls.MPLabel mpLabel2;
-    private MediaPortal.UserInterface.Controls.MPButton mpButtonAll;
-    private MediaPortal.UserInterface.Controls.MPButton mpButtonNone;
-    private System.Windows.Forms.ColumnHeader columnHeader2;
-    private MediaPortal.UserInterface.Controls.MPButton mpButtonClearChannels;
-    private MediaPortal.UserInterface.Controls.MPButton mpButtonAllChannels;
-    private System.Windows.Forms.ImageList imageList1;
-		private System.Windows.Forms.TabControl tabControl1;
-		private System.Windows.Forms.TabPage tabPage1;
-		private MediaPortal.UserInterface.Controls.MPLabel mpLabelChannelCount;
-    private MediaPortal.UserInterface.Controls.MPButton mpButtonAllGrouped;
-    private System.Windows.Forms.ColumnHeader columnHeader4;
-
+    private System.Windows.Forms.LinkLabel linkLabelLanguageNone;
+    private System.Windows.Forms.LinkLabel linkLabelLanguageAll;
+    private System.Windows.Forms.LinkLabel linkLabelRadioNone;
+    private System.Windows.Forms.LinkLabel linkLabelRadioGroupedVisible;
+    private System.Windows.Forms.LinkLabel linkLabelRadioAllGrouped;
+    private System.Windows.Forms.LinkLabel linkLabelRadioAll;
   }
 }
\ No newline at end of file
Index: TvEpgGrabber.cs
===================================================================
--- TvEpgGrabber.cs	(Revision 27464)
+++ TvEpgGrabber.cs	(Arbeitskopie)
@@ -33,11 +33,10 @@
   public partial class TvEpgGrabber : SectionSettings
   {
     private bool _loaded;
-
     private readonly MPListViewStringColumnSorter lvwColumnSorter;
 
     public TvEpgGrabber()
-      : this("TV Epg grabber") {}
+      : this("TV Epg grabber") { }
 
     public TvEpgGrabber(string name)
       : base(name)
@@ -58,14 +57,12 @@
         TvLibrary.Epg.Languages languages = new TvLibrary.Epg.Languages();
         List<String> codes = languages.GetLanguageCodes();
         List<String> list = languages.GetLanguages();
-
         TvBusinessLayer layer = new TvBusinessLayer();
-        Setting setting = layer.GetSetting("epgLanguages");
-
+        Setting setting = layer.GetSetting("epgTVLanguages");
         string values = "";
         for (int j = 0; j < list.Count; j++)
         {
-          ListViewItem item = new ListViewItem(new string[] {list[j], codes[j]});
+          ListViewItem item = new ListViewItem(new string[] { list[j], codes[j] });
           mpListView2.Items.Add(item);
           item.Tag = codes[j];
           if (setting.Value == "")
@@ -82,7 +79,6 @@
           }
         }
         mpListView2.Sort();
-
         if (setting.Value == "")
         {
           setting.Value = values;
@@ -99,7 +95,7 @@
     public override void OnSectionDeActivated()
     {
       TvBusinessLayer layer = new TvBusinessLayer();
-      Setting setting = layer.GetSetting("epgStoreOnlySelected");
+      Setting setting = layer.GetSetting("epgTVStoreOnlySelected");
       setting.Value = mpCheckBoxStoreOnlySelected.Checked ? "yes" : "no";
       setting.Persist();
       base.OnSectionDeActivated();
@@ -113,7 +109,7 @@
       {
         LoadLanguages();
         TvBusinessLayer layer = new TvBusinessLayer();
-        Setting setting = layer.GetSetting("epgStoreOnlySelected");
+        Setting setting = layer.GetSetting("epgTVStoreOnlySelected");
         mpCheckBoxStoreOnlySelected.Checked = (setting.Value == "yes");
         Dictionary<string, CardType> cards = new Dictionary<string, CardType>();
         IList<Card> dbsCards = Card.ListAll();
@@ -123,12 +119,10 @@
         }
         base.OnSectionActivated();
         mpListView1.Items.Clear();
-
-        SqlBuilder sb = new SqlBuilder(StatementType.Select, typeof (Channel));
+        SqlBuilder sb = new SqlBuilder(StatementType.Select, typeof(Channel));
         sb.AddOrderByField(true, "sortOrder");
         SqlStatement stmt = sb.GetStatement(true);
         IList<Channel> channels = ObjectFactory.GetCollection<Channel>(stmt.Execute());
-
         foreach (Channel ch in channels)
         {
           bool analog = false;
@@ -137,13 +131,12 @@
           bool dvbs = false;
           bool atsc = false;
           bool dvbip = false;
+          bool hasFta = false;
+          bool hasScrambled = false;         
           if (ch.IsTv == false)
             continue;
           if (ch.IsWebstream())
             continue;
-
-          bool hasFta = false;
-          bool hasScrambled = false;
           IList<TuningDetail> tuningDetails = ch.ReferringTuningDetail();
           foreach (TuningDetail detail in tuningDetails)
           {
@@ -155,9 +148,7 @@
             {
               hasScrambled = true;
             }
-
           }
-
           int imageIndex;
           if (hasFta && hasScrambled)
           {
@@ -171,7 +162,6 @@
           {
             imageIndex = 3;
           }
-
           ListViewItem item = mpListView1.Items.Add(ch.DisplayName, imageIndex);
           foreach (ChannelMap map in ch.ReferringChannelMap())
           {
@@ -232,7 +222,8 @@
           }
           if (dvbip)
           {
-            if (line != "") line += ",";
+            if (line != "")
+              line += ",";
             line += "DVB-IP";
           }
           item.SubItems.Add(line);
@@ -246,6 +237,45 @@
       }
     }
 
+    public override void SaveSettings()
+    {
+      if (false == _loaded)
+        return;
+      TvBusinessLayer layer = new TvBusinessLayer();
+      Setting setting = layer.GetSetting("epgTVLanguages");
+      setting.Value = ",";
+      for (int i = 0; i < mpListView2.Items.Count; ++i)
+      {
+        if (mpListView2.Items[i].Checked)
+        {
+          string code = (string)mpListView2.Items[i].Tag;
+          setting.Value += code;
+          setting.Value += ",";
+        }
+      }
+      setting.Persist();
+      base.SaveSettings();
+    }
+
+    private void mpListView1_ColumnClick(object sender, ColumnClickEventArgs e)
+    {
+      if (e.Column == lvwColumnSorter.SortColumn)
+      {
+        // Reverse the current sort direction for this column.
+        lvwColumnSorter.Order = lvwColumnSorter.Order == SortOrder.Ascending
+                                  ? SortOrder.Descending
+                                  : SortOrder.Ascending;
+      }
+      else
+      {
+        // Set the column number that is to be sorted; default to ascending.
+        lvwColumnSorter.SortColumn = e.Column;
+        lvwColumnSorter.Order = SortOrder.Ascending;
+      }
+      // Perform the sort with these new sort options.
+      mpListView1.Sort();
+    }
+
     private void mpListView1_ItemChecked(object sender, ItemCheckedEventArgs e)
     {
       Channel channel = e.Item.Tag as Channel;
@@ -255,83 +285,50 @@
       channel.Persist();
     }
 
-    private void mpButtonAll_Click(object sender, EventArgs e)
+    private void linkLabelTVAll_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
-      mpListView2.BeginUpdate();
+      mpListView1.BeginUpdate();
       try
       {
-        for (int i = 0; i < mpListView2.Items.Count; ++i)
+        for (int i = 0; i < mpListView1.Items.Count; ++i)
         {
-          mpListView2.Items[i].Checked = true;
+          mpListView1.Items[i].Checked = true;
         }
-        TvLibrary.Epg.Languages languages = new TvLibrary.Epg.Languages();
-        List<String> codes = languages.GetLanguageCodes();
-        TvBusinessLayer layer = new TvBusinessLayer();
-        Setting setting = layer.GetSetting("epgLanguages");
-        setting.Value = "";
-        foreach (string code in codes)
-        {
-          setting.Value += code;
-          setting.Value += ",";
-        }
-        //Log.WriteFile("tvsetup:epggrabber:all: epglang={0}", setting.Value);
-        setting.Persist();
       }
       finally
       {
-        mpListView2.EndUpdate();
+        mpListView1.EndUpdate();
       }
     }
 
-    private void mpButtonNone_Click(object sender, EventArgs e)
+    private void linkLabelTVAllGrouped_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
-      mpListView2.BeginUpdate();
+      mpListView1.BeginUpdate();
       try
       {
-        for (int i = 0; i < mpListView2.Items.Count; ++i)
+        for (int i = 0; i < mpListView1.Items.Count; ++i)
         {
-          mpListView2.Items[i].Checked = false;
+          Channel ch = (Channel)mpListView1.Items[i].Tag;
+          mpListView1.Items[i].Checked = (ch.ReferringGroupMap().Count > 1);
+          // if count > 1 we assume that the channel has one or more custom group(s) associated with it.
         }
-        TvBusinessLayer layer = new TvBusinessLayer();
-        Setting setting = layer.GetSetting("epgLanguages");
-        setting.Value = ",";
-        Log.WriteFile("tvsetup:epggrabber:none: epglang={0}", setting.Value);
-        setting.Persist();
       }
       finally
       {
-        mpListView2.EndUpdate();
+        mpListView1.EndUpdate();
       }
     }
 
-    public override void SaveSettings()
+    private void linkLabelTVGroupedVisible_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
-      if (false == _loaded)
-        return;
-      TvBusinessLayer layer = new TvBusinessLayer();
-      Setting setting = layer.GetSetting("epgLanguages");
-      setting.Value = ",";
-      for (int i = 0; i < mpListView2.Items.Count; ++i)
-      {
-        if (mpListView2.Items[i].Checked)
-        {
-          string code = (string)mpListView2.Items[i].Tag;
-          setting.Value += code;
-          setting.Value += ",";
-        }
-      }
-      setting.Persist();
-      base.SaveSettings();
-    }
-
-    private void mpButtonAllChannels_Click(object sender, EventArgs e)
-    {
       mpListView1.BeginUpdate();
       try
       {
         for (int i = 0; i < mpListView1.Items.Count; ++i)
         {
-          mpListView1.Items[i].Checked = true;
+          Channel ch = (Channel)mpListView1.Items[i].Tag;
+          mpListView1.Items[i].Checked = (ch.ReferringGroupMap().Count > 1 && ch.VisibleInGuide);
+          // if count > 1 we assume that the channel has one or more custom group(s) associated with it.
         }
       }
       finally
@@ -340,7 +337,7 @@
       }
     }
 
-    private void mpButtonNoneChannels_Click(object sender, EventArgs e)
+    private void linkLabelTVNone_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
       mpListView1.BeginUpdate();
       try
@@ -356,42 +353,53 @@
       }
     }
 
-    private void mpButtonAllGrouped_Click(object sender, EventArgs e)
+    private void linkLabelLanguageAll_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
-      mpListView1.BeginUpdate();
+      mpListView2.BeginUpdate();
       try
       {
-        for (int i = 0; i < mpListView1.Items.Count; ++i)
+        for (int i = 0; i < mpListView2.Items.Count; ++i)
         {
-          Channel ch = (Channel)mpListView1.Items[i].Tag;
-          mpListView1.Items[i].Checked = (ch.ReferringGroupMap().Count > 1);
-          // if count > 1 we assume that the channel has one or more custom group(s) associated with it.
+          mpListView2.Items[i].Checked = true;
         }
+        TvLibrary.Epg.Languages languages = new TvLibrary.Epg.Languages();
+        List<String> codes = languages.GetLanguageCodes();
+        TvBusinessLayer layer = new TvBusinessLayer();
+        Setting setting = layer.GetSetting("epgTVLanguages");
+        setting.Value = "";
+        foreach (string code in codes)
+        {
+          setting.Value += code;
+          setting.Value += ",";
+        }
+        //Log.WriteFile("tvsetup:epggrabber:all: epglang={0}", setting.Value);
+        setting.Persist();
       }
       finally
       {
-        mpListView1.EndUpdate();
+        mpListView2.EndUpdate();
       }
     }
 
-    private void mpListView1_ColumnClick(object sender, ColumnClickEventArgs e)
+    private void linkLabelLanguageNone_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
     {
-      if (e.Column == lvwColumnSorter.SortColumn)
+      mpListView2.BeginUpdate();
+      try
       {
-        // Reverse the current sort direction for this column.
-        lvwColumnSorter.Order = lvwColumnSorter.Order == SortOrder.Ascending
-                                  ? SortOrder.Descending
-                                  : SortOrder.Ascending;
+        for (int i = 0; i < mpListView2.Items.Count; ++i)
+        {
+          mpListView2.Items[i].Checked = false;
+        }
+        TvBusinessLayer layer = new TvBusinessLayer();
+        Setting setting = layer.GetSetting("epgTVLanguages");
+        setting.Value = ",";
+        Log.WriteFile("tvsetup:epggrabber:none: epglang={0}", setting.Value);
+        setting.Persist();
       }
-      else
+      finally
       {
-        // Set the column number that is to be sorted; default to ascending.
-        lvwColumnSorter.SortColumn = e.Column;
-        lvwColumnSorter.Order = SortOrder.Ascending;
+        mpListView2.EndUpdate();
       }
-
-      // Perform the sort with these new sort options.
-      mpListView1.Sort();
     }
   }
 }
\ No newline at end of file
Index: TvEpgGrabber.Designer.cs
===================================================================
--- TvEpgGrabber.Designer.cs	(Revision 27464)
+++ TvEpgGrabber.Designer.cs	(Arbeitskopie)
@@ -30,83 +30,100 @@
     {
       this.components = new System.ComponentModel.Container();
       System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(TvEpgGrabber));
-      this.imageList1 = new System.Windows.Forms.ImageList(this.components);
-      this.tabControl1 = new System.Windows.Forms.TabControl();
-      this.tabPage1 = new System.Windows.Forms.TabPage();
-      this.mpButtonAllGrouped = new MediaPortal.UserInterface.Controls.MPButton();
+      this.linkLabelLanguageNone = new System.Windows.Forms.LinkLabel();
+      this.linkLabelLanguageAll = new System.Windows.Forms.LinkLabel();
+      this.linkLabelTVNone = new System.Windows.Forms.LinkLabel();
+      this.linkLabelTVGroupedVisible = new System.Windows.Forms.LinkLabel();
+      this.linkLabelTVAll = new System.Windows.Forms.LinkLabel();
+      this.columnHeader1 = new System.Windows.Forms.ColumnHeader();
+      this.linkLabelTVAllGrouped = new System.Windows.Forms.LinkLabel();
       this.mpCheckBoxStoreOnlySelected = new MediaPortal.UserInterface.Controls.MPCheckBox();
-      this.mpButtonNoneChannels = new MediaPortal.UserInterface.Controls.MPButton();
-      this.mpButtonAllChannels = new MediaPortal.UserInterface.Controls.MPButton();
-      this.mpButtonNone = new MediaPortal.UserInterface.Controls.MPButton();
-      this.mpButtonAll = new MediaPortal.UserInterface.Controls.MPButton();
       this.mpLabel2 = new MediaPortal.UserInterface.Controls.MPLabel();
+      this.imageList1 = new System.Windows.Forms.ImageList(this.components);
+      this.columnHeader3 = new System.Windows.Forms.ColumnHeader();
       this.mpListView2 = new MediaPortal.UserInterface.Controls.MPListView();
       this.columnHeader2 = new System.Windows.Forms.ColumnHeader();
       this.columnHeader4 = new System.Windows.Forms.ColumnHeader();
       this.mpLabel1 = new MediaPortal.UserInterface.Controls.MPLabel();
       this.mpListView1 = new MediaPortal.UserInterface.Controls.MPListView();
-      this.columnHeader1 = new System.Windows.Forms.ColumnHeader();
-      this.columnHeader3 = new System.Windows.Forms.ColumnHeader();
+      this.tabPage1 = new System.Windows.Forms.TabPage();
       this.mpLabelChannelCount = new MediaPortal.UserInterface.Controls.MPLabel();
+      this.tabControl1 = new System.Windows.Forms.TabControl();
+      this.tabPage1.SuspendLayout();
       this.tabControl1.SuspendLayout();
-      this.tabPage1.SuspendLayout();
       this.SuspendLayout();
       // 
-      // imageList1
+      // linkLabelLanguageNone
       // 
-      this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
-      this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
-      this.imageList1.Images.SetKeyName(0, "radio_fta_.png");
-      this.imageList1.Images.SetKeyName(1, "radio_scrambled.png");
-      this.imageList1.Images.SetKeyName(2, "icon.radio_scrambled_and_fta.png");
-      this.imageList1.Images.SetKeyName(3, "tv_fta_.png");
-      this.imageList1.Images.SetKeyName(4, "tv_scrambled.png");
-      this.imageList1.Images.SetKeyName(5, "icon.tv_scrambled_and_fta.png");
+      this.linkLabelLanguageNone.AutoSize = true;
+      this.linkLabelLanguageNone.Location = new System.Drawing.Point(280, 376);
+      this.linkLabelLanguageNone.Name = "linkLabelLanguageNone";
+      this.linkLabelLanguageNone.Size = new System.Drawing.Size(33, 13);
+      this.linkLabelLanguageNone.TabIndex = 24;
+      this.linkLabelLanguageNone.TabStop = true;
+      this.linkLabelLanguageNone.Text = "None";
+      this.linkLabelLanguageNone.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelLanguageNone_LinkClicked);
       // 
-      // tabControl1
+      // linkLabelLanguageAll
       // 
-      this.tabControl1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
-                  | System.Windows.Forms.AnchorStyles.Left)
-                  | System.Windows.Forms.AnchorStyles.Right)));
-      this.tabControl1.Controls.Add(this.tabPage1);
-      this.tabControl1.Location = new System.Drawing.Point(3, 3);
-      this.tabControl1.Name = "tabControl1";
-      this.tabControl1.SelectedIndex = 0;
-      this.tabControl1.Size = new System.Drawing.Size(485, 431);
-      this.tabControl1.TabIndex = 10;
+      this.linkLabelLanguageAll.AutoSize = true;
+      this.linkLabelLanguageAll.Location = new System.Drawing.Point(256, 376);
+      this.linkLabelLanguageAll.Name = "linkLabelLanguageAll";
+      this.linkLabelLanguageAll.Size = new System.Drawing.Size(18, 13);
+      this.linkLabelLanguageAll.TabIndex = 23;
+      this.linkLabelLanguageAll.TabStop = true;
+      this.linkLabelLanguageAll.Text = "All";
+      this.linkLabelLanguageAll.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelLanguageAll_LinkClicked);
       // 
-      // tabPage1
+      // linkLabelTVNone
       // 
-      this.tabPage1.Controls.Add(this.mpButtonAllGrouped);
-      this.tabPage1.Controls.Add(this.mpCheckBoxStoreOnlySelected);
-      this.tabPage1.Controls.Add(this.mpButtonNoneChannels);
-      this.tabPage1.Controls.Add(this.mpButtonAllChannels);
-      this.tabPage1.Controls.Add(this.mpButtonNone);
-      this.tabPage1.Controls.Add(this.mpButtonAll);
-      this.tabPage1.Controls.Add(this.mpLabel2);
-      this.tabPage1.Controls.Add(this.mpListView2);
-      this.tabPage1.Controls.Add(this.mpLabel1);
-      this.tabPage1.Controls.Add(this.mpListView1);
-      this.tabPage1.Controls.Add(this.mpLabelChannelCount);
-      this.tabPage1.Location = new System.Drawing.Point(4, 22);
-      this.tabPage1.Name = "tabPage1";
-      this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
-      this.tabPage1.Size = new System.Drawing.Size(477, 405);
-      this.tabPage1.TabIndex = 0;
-      this.tabPage1.Text = "TV Epg grabber";
-      this.tabPage1.UseVisualStyleBackColor = true;
+      this.linkLabelTVNone.AutoSize = true;
+      this.linkLabelTVNone.Location = new System.Drawing.Point(192, 376);
+      this.linkLabelTVNone.Name = "linkLabelTVNone";
+      this.linkLabelTVNone.Size = new System.Drawing.Size(33, 13);
+      this.linkLabelTVNone.TabIndex = 22;
+      this.linkLabelTVNone.TabStop = true;
+      this.linkLabelTVNone.Text = "None";
+      this.linkLabelTVNone.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelTVNone_LinkClicked);
       // 
-      // mpButtonAllGrouped
+      // linkLabelTVGroupedVisible
       // 
-      this.mpButtonAllGrouped.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-      this.mpButtonAllGrouped.Location = new System.Drawing.Point(77, 374);
-      this.mpButtonAllGrouped.Name = "mpButtonAllGrouped";
-      this.mpButtonAllGrouped.Size = new System.Drawing.Size(75, 23);
-      this.mpButtonAllGrouped.TabIndex = 18;
-      this.mpButtonAllGrouped.Text = "All Grouped";
-      this.mpButtonAllGrouped.UseVisualStyleBackColor = true;
-      this.mpButtonAllGrouped.Click += new System.EventHandler(this.mpButtonAllGrouped_Click);
+      this.linkLabelTVGroupedVisible.AutoSize = true;
+      this.linkLabelTVGroupedVisible.Location = new System.Drawing.Point(96, 376);
+      this.linkLabelTVGroupedVisible.Name = "linkLabelTVGroupedVisible";
+      this.linkLabelTVGroupedVisible.Size = new System.Drawing.Size(90, 13);
+      this.linkLabelTVGroupedVisible.TabIndex = 21;
+      this.linkLabelTVGroupedVisible.TabStop = true;
+      this.linkLabelTVGroupedVisible.Text = "Grouped && Visible";
+      this.linkLabelTVGroupedVisible.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelTVGroupedVisible_LinkClicked);
       // 
+      // linkLabelTVAll
+      // 
+      this.linkLabelTVAll.AutoSize = true;
+      this.linkLabelTVAll.Location = new System.Drawing.Point(8, 376);
+      this.linkLabelTVAll.Name = "linkLabelTVAll";
+      this.linkLabelTVAll.Size = new System.Drawing.Size(18, 13);
+      this.linkLabelTVAll.TabIndex = 19;
+      this.linkLabelTVAll.TabStop = true;
+      this.linkLabelTVAll.Text = "All";
+      this.linkLabelTVAll.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelTVAll_LinkClicked);
+      // 
+      // columnHeader1
+      // 
+      this.columnHeader1.Text = "Name";
+      this.columnHeader1.Width = 125;
+      // 
+      // linkLabelTVAllGrouped
+      // 
+      this.linkLabelTVAllGrouped.AutoSize = true;
+      this.linkLabelTVAllGrouped.Location = new System.Drawing.Point(32, 376);
+      this.linkLabelTVAllGrouped.Name = "linkLabelTVAllGrouped";
+      this.linkLabelTVAllGrouped.Size = new System.Drawing.Size(62, 13);
+      this.linkLabelTVAllGrouped.TabIndex = 20;
+      this.linkLabelTVAllGrouped.TabStop = true;
+      this.linkLabelTVAllGrouped.Text = "All Grouped";
+      this.linkLabelTVAllGrouped.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelTVAllGrouped_LinkClicked);
+      // 
       // mpCheckBoxStoreOnlySelected
       // 
       this.mpCheckBoxStoreOnlySelected.AutoSize = true;
@@ -118,59 +135,31 @@
       this.mpCheckBoxStoreOnlySelected.Text = "Store data only for selected channels";
       this.mpCheckBoxStoreOnlySelected.UseVisualStyleBackColor = true;
       // 
-      // mpButtonNoneChannels
-      // 
-      this.mpButtonNoneChannels.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-      this.mpButtonNoneChannels.Location = new System.Drawing.Point(158, 374);
-      this.mpButtonNoneChannels.Name = "mpButtonNoneChannels";
-      this.mpButtonNoneChannels.Size = new System.Drawing.Size(60, 23);
-      this.mpButtonNoneChannels.TabIndex = 15;
-      this.mpButtonNoneChannels.Text = "None";
-      this.mpButtonNoneChannels.UseVisualStyleBackColor = true;
-      this.mpButtonNoneChannels.Click += new System.EventHandler(this.mpButtonNoneChannels_Click);
-      // 
-      // mpButtonAllChannels
-      // 
-      this.mpButtonAllChannels.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-      this.mpButtonAllChannels.Location = new System.Drawing.Point(10, 374);
-      this.mpButtonAllChannels.Name = "mpButtonAllChannels";
-      this.mpButtonAllChannels.Size = new System.Drawing.Size(61, 23);
-      this.mpButtonAllChannels.TabIndex = 14;
-      this.mpButtonAllChannels.Text = "All";
-      this.mpButtonAllChannels.UseVisualStyleBackColor = true;
-      this.mpButtonAllChannels.Click += new System.EventHandler(this.mpButtonAllChannels_Click);
-      // 
-      // mpButtonNone
-      // 
-      this.mpButtonNone.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
-      this.mpButtonNone.Location = new System.Drawing.Point(396, 374);
-      this.mpButtonNone.Name = "mpButtonNone";
-      this.mpButtonNone.Size = new System.Drawing.Size(75, 23);
-      this.mpButtonNone.TabIndex = 16;
-      this.mpButtonNone.Text = "None";
-      this.mpButtonNone.UseVisualStyleBackColor = true;
-      this.mpButtonNone.Click += new System.EventHandler(this.mpButtonNone_Click);
-      // 
-      // mpButtonAll
-      // 
-      this.mpButtonAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
-      this.mpButtonAll.Location = new System.Drawing.Point(315, 374);
-      this.mpButtonAll.Name = "mpButtonAll";
-      this.mpButtonAll.Size = new System.Drawing.Size(75, 23);
-      this.mpButtonAll.TabIndex = 13;
-      this.mpButtonAll.Text = "All";
-      this.mpButtonAll.UseVisualStyleBackColor = true;
-      this.mpButtonAll.Click += new System.EventHandler(this.mpButtonAll_Click);
-      // 
       // mpLabel2
       // 
       this.mpLabel2.AutoSize = true;
       this.mpLabel2.Location = new System.Drawing.Point(251, 33);
       this.mpLabel2.Name = "mpLabel2";
-      this.mpLabel2.Size = new System.Drawing.Size(131, 13);
+      this.mpLabel2.Size = new System.Drawing.Size(187, 13);
       this.mpLabel2.TabIndex = 12;
-      this.mpLabel2.Text = "Filter for these languages: ";
+      this.mpLabel2.Text = "Grab EPG for the following languages:";
       // 
+      // imageList1
+      // 
+      this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
+      this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
+      this.imageList1.Images.SetKeyName(0, "radio_fta_.png");
+      this.imageList1.Images.SetKeyName(1, "radio_scrambled.png");
+      this.imageList1.Images.SetKeyName(2, "icon.radio_scrambled_and_fta.png");
+      this.imageList1.Images.SetKeyName(3, "tv_fta_.png");
+      this.imageList1.Images.SetKeyName(4, "tv_scrambled.png");
+      this.imageList1.Images.SetKeyName(5, "icon.tv_scrambled_and_fta.png");
+      // 
+      // columnHeader3
+      // 
+      this.columnHeader3.Text = "Types";
+      this.columnHeader3.Width = 61;
+      // 
       // mpListView2
       // 
       this.mpListView2.AllowDrop = true;
@@ -224,7 +213,7 @@
       this.mpListView1.LargeImageList = this.imageList1;
       this.mpListView1.Location = new System.Drawing.Point(10, 51);
       this.mpListView1.Name = "mpListView1";
-      this.mpListView1.Size = new System.Drawing.Size(208, 312);
+      this.mpListView1.Size = new System.Drawing.Size(214, 312);
       this.mpListView1.SmallImageList = this.imageList1;
       this.mpListView1.TabIndex = 9;
       this.mpListView1.UseCompatibleStateImageBehavior = false;
@@ -232,16 +221,28 @@
       this.mpListView1.ItemChecked += new System.Windows.Forms.ItemCheckedEventHandler(this.mpListView1_ItemChecked);
       this.mpListView1.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.mpListView1_ColumnClick);
       // 
-      // columnHeader1
+      // tabPage1
       // 
-      this.columnHeader1.Text = "Name";
-      this.columnHeader1.Width = 125;
+      this.tabPage1.Controls.Add(this.linkLabelLanguageNone);
+      this.tabPage1.Controls.Add(this.linkLabelLanguageAll);
+      this.tabPage1.Controls.Add(this.linkLabelTVNone);
+      this.tabPage1.Controls.Add(this.linkLabelTVGroupedVisible);
+      this.tabPage1.Controls.Add(this.linkLabelTVAllGrouped);
+      this.tabPage1.Controls.Add(this.linkLabelTVAll);
+      this.tabPage1.Controls.Add(this.mpCheckBoxStoreOnlySelected);
+      this.tabPage1.Controls.Add(this.mpLabel2);
+      this.tabPage1.Controls.Add(this.mpListView2);
+      this.tabPage1.Controls.Add(this.mpLabel1);
+      this.tabPage1.Controls.Add(this.mpListView1);
+      this.tabPage1.Controls.Add(this.mpLabelChannelCount);
+      this.tabPage1.Location = new System.Drawing.Point(4, 22);
+      this.tabPage1.Name = "tabPage1";
+      this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
+      this.tabPage1.Size = new System.Drawing.Size(477, 405);
+      this.tabPage1.TabIndex = 0;
+      this.tabPage1.Text = "TV Epg grabber";
+      this.tabPage1.UseVisualStyleBackColor = true;
       // 
-      // columnHeader3
-      // 
-      this.columnHeader3.Text = "Types";
-      this.columnHeader3.Width = 61;
-      // 
       // mpLabelChannelCount
       // 
       this.mpLabelChannelCount.AutoSize = true;
@@ -250,6 +251,18 @@
       this.mpLabelChannelCount.Size = new System.Drawing.Size(0, 13);
       this.mpLabelChannelCount.TabIndex = 2;
       // 
+      // tabControl1
+      // 
+      this.tabControl1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
+                  | System.Windows.Forms.AnchorStyles.Left)
+                  | System.Windows.Forms.AnchorStyles.Right)));
+      this.tabControl1.Controls.Add(this.tabPage1);
+      this.tabControl1.Location = new System.Drawing.Point(3, 3);
+      this.tabControl1.Name = "tabControl1";
+      this.tabControl1.SelectedIndex = 0;
+      this.tabControl1.Size = new System.Drawing.Size(485, 431);
+      this.tabControl1.TabIndex = 11;
+      // 
       // TvEpgGrabber
       // 
       this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
@@ -257,33 +270,33 @@
       this.Controls.Add(this.tabControl1);
       this.Name = "TvEpgGrabber";
       this.Size = new System.Drawing.Size(491, 437);
-      this.tabControl1.ResumeLayout(false);
       this.tabPage1.ResumeLayout(false);
       this.tabPage1.PerformLayout();
+      this.tabControl1.ResumeLayout(false);
       this.ResumeLayout(false);
 
     }
 
     #endregion
 
-		private System.Windows.Forms.ImageList imageList1;
-		private System.Windows.Forms.TabControl tabControl1;
-		private System.Windows.Forms.TabPage tabPage1;
-		private MediaPortal.UserInterface.Controls.MPButton mpButtonAllGrouped;
-		private MediaPortal.UserInterface.Controls.MPCheckBox mpCheckBoxStoreOnlySelected;
-		private MediaPortal.UserInterface.Controls.MPButton mpButtonNoneChannels;
-		private MediaPortal.UserInterface.Controls.MPButton mpButtonAllChannels;
-		private MediaPortal.UserInterface.Controls.MPButton mpButtonNone;
-		private MediaPortal.UserInterface.Controls.MPButton mpButtonAll;
-		private MediaPortal.UserInterface.Controls.MPLabel mpLabel2;
-		private MediaPortal.UserInterface.Controls.MPListView mpListView2;
-		private System.Windows.Forms.ColumnHeader columnHeader2;
-		private MediaPortal.UserInterface.Controls.MPLabel mpLabel1;
-		private MediaPortal.UserInterface.Controls.MPListView mpListView1;
-		private System.Windows.Forms.ColumnHeader columnHeader1;
-		private System.Windows.Forms.ColumnHeader columnHeader3;
-		private MediaPortal.UserInterface.Controls.MPLabel mpLabelChannelCount;
+    private System.Windows.Forms.LinkLabel linkLabelLanguageNone;
+    private System.Windows.Forms.LinkLabel linkLabelLanguageAll;
+    private System.Windows.Forms.LinkLabel linkLabelTVNone;
+    private System.Windows.Forms.LinkLabel linkLabelTVGroupedVisible;
+    private System.Windows.Forms.LinkLabel linkLabelTVAll;
+    private System.Windows.Forms.ColumnHeader columnHeader1;
+    private System.Windows.Forms.LinkLabel linkLabelTVAllGrouped;
+    private MediaPortal.UserInterface.Controls.MPCheckBox mpCheckBoxStoreOnlySelected;
+    private MediaPortal.UserInterface.Controls.MPLabel mpLabel2;
+    private System.Windows.Forms.ImageList imageList1;
+    private System.Windows.Forms.ColumnHeader columnHeader3;
+    private MediaPortal.UserInterface.Controls.MPListView mpListView2;
+    private System.Windows.Forms.ColumnHeader columnHeader2;
     private System.Windows.Forms.ColumnHeader columnHeader4;
-
+    private MediaPortal.UserInterface.Controls.MPLabel mpLabel1;
+    private MediaPortal.UserInterface.Controls.MPListView mpListView1;
+    private System.Windows.Forms.TabPage tabPage1;
+    private MediaPortal.UserInterface.Controls.MPLabel mpLabelChannelCount;
+    private System.Windows.Forms.TabControl tabControl1;
   }
 }
\ No newline at end of file
