OSDN Git Service

WinGui:
authorsr55 <sr55@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Fri, 17 Jul 2009 23:37:33 +0000 (23:37 +0000)
committersr55 <sr55@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Fri, 17 Jul 2009 23:37:33 +0000 (23:37 +0000)
- Added new options:  preferred language,  "Dub Foreign language audio" and "Use Foreign language audio and Subtitles"
- Changed built-in language list to native spellings.
- Fixes to CLI Scan Parser AudioTrack.\

- Note: Subtitles panel is not hooked up for this yet.

git-svn-id: svn://localhost/HandBrake/trunk@2709 b64f7644-9d1e-0410-96f1-a4d463321fa5

win/C#/Controls/AudioPanel.cs
win/C#/Controls/Subtitles.cs
win/C#/Functions/Main.cs
win/C#/HandBrakeCS.csproj
win/C#/Parsing/AudioTrack.cs
win/C#/Properties/Settings.Designer.cs
win/C#/Properties/Settings.settings
win/C#/app.config
win/C#/frmOptions.Designer.cs
win/C#/frmOptions.cs
win/C#/frmOptions.resx

index d086999..c846f50 100644 (file)
@@ -227,7 +227,29 @@ namespace Handbrake.Controls
             drp_audioTrack.Items.Add("Automatic");\r
             drp_audioTrack.Items.Add("None");\r
             drp_audioTrack.Items.AddRange(selectedTitle.AudioTracks.ToArray());\r
-            drp_audioTrack.SelectedIndex = 0;\r
+\r
+            // Handle Native Language and "Dub Foreign language audio" and "Use Foreign language audio and Subtitles" Options\r
+            if (Properties.Settings.Default.NativeLanguage == "Any")\r
+                drp_audioTrack.SelectedIndex = 0;\r
+            else\r
+            {\r
+                if (Properties.Settings.Default.DubAudio) // "Dub Foreign language audio" \r
+                {\r
+                    int i = 0;\r
+                    foreach (object item in drp_audioTrack.Items)\r
+                    {\r
+                        if (item.ToString().Contains(Properties.Settings.Default.NativeLanguage))\r
+                            drp_audioTrack.SelectedIndex = i;\r
+\r
+                        i++;\r
+                    }\r
+\r
+                    foreach (ListViewItem item in lv_audioList.Items)\r
+                        item.SubItems[1].Text = drp_audioTrack.SelectedItem.ToString();     \r
+                }\r
+                else\r
+                    drp_audioTrack.SelectedIndex = 0; // "Use Foreign language audio and Subtitles"\r
+            }\r
             drp_audioMix.SelectedIndex = 0;\r
         }\r
         public ListView getAudioPanel()\r
index c785cde..9036a6c 100644 (file)
@@ -22,6 +22,10 @@ namespace Handbrake.Controls
         }\r
 \r
         private int FileContainer;\r
+        public void setSubtitleTrackAuto()\r
+        {\r
+            //TODO\r
+        }\r
         public void setContainer(int value)\r
         {\r
             FileContainer = value;\r
index 54ef9d4..075bdfa 100644 (file)
@@ -472,9 +472,9 @@ namespace Handbrake.Functions
                                                               {"Corsican", "cos"},\r
                                                               {"Cree", "cre"},\r
                                                               {"Czech", "ces"},\r
-                                                              {"Danish", "dan"},\r
+                                                              {"Dansk", "dan"},\r
                                                               {"Divehi", "div"},\r
-                                                              {"Dutch", "nld"},\r
+                                                              {"Nederlands", "nld"},\r
                                                               {"Dzongkha", "dzo"},\r
                                                               {"English", "eng"},\r
                                                               {"Esperanto", "epo"},\r
@@ -482,12 +482,12 @@ namespace Handbrake.Functions
                                                               {"Ewe", "ewe"},\r
                                                               {"Faroese", "fao"},\r
                                                               {"Fijian", "fij"},\r
-                                                              {"Finnish", "fin"},\r
-                                                              {"French", "fra"},\r
+                                                              {"Suomi", "fin"},\r
+                                                              {"Francais", "fra"},\r
                                                               {"Western Frisian", "fry"},\r
                                                               {"Fulah", "ful"},\r
                                                               {"Georgian", "kat"},\r
-                                                              {"German", "deu"},\r
+                                                              {"Deutsch", "deu"},\r
                                                               {"Gaelic (Scots)", "gla"},\r
                                                               {"Irish", "gle"},\r
                                                               {"Galician", "glg"},\r
@@ -501,9 +501,9 @@ namespace Handbrake.Functions
                                                               {"Herero", "her"},\r
                                                               {"Hindi", "hin"},\r
                                                               {"Hiri Motu", "hmo"},\r
-                                                              {"Hungarian", "hun"},\r
+                                                              {"Magyar", "hun"},\r
                                                               {"Igbo", "ibo"},\r
-                                                              {"Icelandic", "isl"},\r
+                                                              {"Islenska", "isl"},\r
                                                               {"Ido", "ido"},\r
                                                               {"Sichuan Yi", "iii"},\r
                                                               {"Inuktitut", "iku"},\r
@@ -511,7 +511,7 @@ namespace Handbrake.Functions
                                                               {"Interlingua", "ina"},\r
                                                               {"Indonesian", "ind"},\r
                                                               {"Inupiaq", "ipk"},\r
-                                                              {"Italian", "ita"},\r
+                                                              {"Italiano", "ita"},\r
                                                               {"Javanese", "jav"},\r
                                                               {"Japanese", "jpn"},\r
                                                               {"Kalaallisut", "kal"},\r
@@ -555,7 +555,7 @@ namespace Handbrake.Functions
                                                               {"Nepali", "nep"},\r
                                                               {"Norwegian Nynorsk", "nno"},\r
                                                               {"Norwegian Bokmål", "nob"},\r
-                                                              {"Norwegian", "nor"},\r
+                                                              {"Norsk", "nor"},\r
                                                               {"Chichewa; Nyanja", "nya"},\r
                                                               {"Occitan", "oci"},\r
                                                               {"Ojibwa", "oji"},\r
@@ -566,7 +566,7 @@ namespace Handbrake.Functions
                                                               {"Persian", "fas"},\r
                                                               {"Pali", "pli"},\r
                                                               {"Polish", "pol"},\r
-                                                              {"Portuguese", "por"},\r
+                                                              {"Portugues", "por"},\r
                                                               {"Pushto", "pus"},\r
                                                               {"Quechua", "que"},\r
                                                               {"Romansh", "roh"},\r
@@ -576,7 +576,7 @@ namespace Handbrake.Functions
                                                               {"Sango", "sag"},\r
                                                               {"Sanskrit", "san"},\r
                                                               {"Serbian", "srp"},\r
-                                                              {"Croatian", "hrv"},\r
+                                                              {"Hrvatski", "hrv"},\r
                                                               {"Sinhala", "sin"},\r
                                                               {"Slovak", "slk"},\r
                                                               {"Slovenian", "slv"},\r
@@ -586,12 +586,12 @@ namespace Handbrake.Functions
                                                               {"Sindhi", "snd"},\r
                                                               {"Somali", "som"},\r
                                                               {"Sotho Southern", "sot"},\r
-                                                              {"Spanish", "spa"},\r
+                                                              {"Espanol", "spa"},\r
                                                               {"Sardinian", "srd"},\r
                                                               {"Swati", "ssw"},\r
                                                               {"Sundanese", "sun"},\r
                                                               {"Swahili", "swa"},\r
-                                                              {"Swedish", "swe"},\r
+                                                              {"Svenska", "swe"},\r
                                                               {"Tahitian", "tah"},\r
                                                               {"Tamil", "tam"},\r
                                                               {"Tatar", "tat"},\r
index fda90e5..3f9aa4d 100644 (file)
       <DependentUpon>frmSplashScreen.cs</DependentUpon>\r
     </Compile>\r
     <Compile Include="EncodeQueue\Job.cs" />\r
+    <Compile Include="Settings.cs" />\r
   </ItemGroup>\r
   <ItemGroup>\r
     <Content Include="handbrakepineapple.ico" />\r
index 86c2b6e..c4e1bbc 100644 (file)
@@ -22,6 +22,7 @@ namespace Handbrake.Parsing
         private string m_language;\r
         private string m_subFormat;\r
         private int m_trackNumber;\r
+        private string m_iso639_2;\r
 \r
         /// <summary>\r
         /// The track number of this Audio Track\r
@@ -71,6 +72,11 @@ namespace Handbrake.Parsing
             get { return m_bitrate; }\r
         }\r
 \r
+        public string ISO639_2\r
+        {\r
+            get { return m_iso639_2;  }\r
+        }\r
+\r
         /// <summary>\r
         /// Override of the ToString method to make this object easier to use in the UI\r
         /// </summary>\r
@@ -86,34 +92,29 @@ namespace Handbrake.Parsing
         public static AudioTrack Parse(StringReader output)\r
         {\r
             String audio_track = output.ReadLine();\r
-            Match m = Regex.Match(audio_track,\r
-                                  @"^    \+ ([0-9]*), ([A-Za-z0-9]*) \((.*)\) \((.*)\), ([0-9]*)Hz, ([0-9]*)bps");\r
-            Match y = Regex.Match(audio_track, @"^    \+ ([0-9]*), ([A-Za-z0-9]*) \((.*)\)");\r
-            if (m.Success)\r
-            {\r
-                var thisTrack = new AudioTrack\r
-                                    {\r
-                                        m_trackNumber = int.Parse(m.Groups[1].Value.Trim()),\r
-                                        m_language = m.Groups[2].Value,\r
-                                        m_format = m.Groups[3].Value,\r
-                                        m_subFormat = m.Groups[4].Value,\r
-                                        m_frequency = int.Parse(m.Groups[5].Value.Trim()),\r
-                                        m_bitrate = int.Parse(m.Groups[6].Value.Trim())\r
-                                    };\r
-                return thisTrack;\r
-            }\r
-            \r
-            if (y.Success)\r
+            Match m = Regex.Match(audio_track, @"^    \+ ([0-9]*), ([A-Za-z0-9]*) \((.*)\) \((.*)\)");\r
+            Match track = Regex.Match(audio_track, @"^    \+ ([0-9]*), ([A-Za-z0-9]*) \((.*)\)"); // ID and Language\r
+            Match iso639_2 = Regex.Match(audio_track, @"iso639-2: ([a-zA-Z]*)\)");\r
+            Match samplerate = Regex.Match(audio_track, @"([0-9]*)Hz");\r
+            Match bitrate = Regex.Match(audio_track, @"([0-9]*)bps");\r
+\r
+            string subformat = m.Groups[4].Value.Trim().Contains("iso639") ? null : m.Groups[4].Value;\r
+\r
+            if (track.Success)\r
             {\r
                 var thisTrack = new AudioTrack\r
-                                    {\r
-                                        m_trackNumber = int.Parse(y.Groups[1].Value.Trim()),\r
-                                        m_language = y.Groups[2].Value,\r
-                                        m_format = y.Groups[3].Value\r
-                                    };\r
-                return thisTrack;\r
+                {\r
+                    m_trackNumber = int.Parse(track.Groups[1].Value.Trim()),\r
+                    m_language = track.Groups[2].Value,\r
+                    m_format = m.Groups[3].Value,\r
+                    m_subFormat = subformat,\r
+                    m_frequency = int.Parse(samplerate.Groups[0].Value.Replace("Hz","").Trim()),\r
+                    m_bitrate = int.Parse(bitrate.Groups[0].Value.Replace("bps","").Trim()),\r
+                    m_iso639_2 = iso639_2.Value.Replace("iso639-2: ", "").Replace(")", "")\r
+                };\r
+                return thisTrack; \r
             }\r
-            \r
+          \r
             return null;\r
         }\r
 \r
index d740544..f1cc044 100644 (file)
@@ -1,7 +1,7 @@
 //------------------------------------------------------------------------------\r
 // <auto-generated>\r
 //     This code was generated by a tool.\r
-//     Runtime Version:2.0.50727.4918\r
+//     Runtime Version:2.0.50727.3082\r
 //\r
 //     Changes to this file may cause incorrect behavior and will be lost if\r
 //     the code is regenerated.\r
@@ -417,5 +417,29 @@ namespace Handbrake.Properties {
                 this["PromptOnUnmatchingQueries"] = value;\r
             }\r
         }\r
+        \r
+        [global::System.Configuration.UserScopedSettingAttribute()]\r
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\r
+        [global::System.Configuration.DefaultSettingValueAttribute("Any")]\r
+        public string NativeLanguage {\r
+            get {\r
+                return ((string)(this["NativeLanguage"]));\r
+            }\r
+            set {\r
+                this["NativeLanguage"] = value;\r
+            }\r
+        }\r
+        \r
+        [global::System.Configuration.UserScopedSettingAttribute()]\r
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\r
+        [global::System.Configuration.DefaultSettingValueAttribute("False")]\r
+        public bool DubAudio {\r
+            get {\r
+                return ((bool)(this["DubAudio"]));\r
+            }\r
+            set {\r
+                this["DubAudio"] = value;\r
+            }\r
+        }\r
     }\r
 }\r
index 5f43ded..ebd6f44 100644 (file)
     <Setting Name="PromptOnUnmatchingQueries" Type="System.Boolean" Scope="User">\r
       <Value Profile="(Default)">True</Value>\r
     </Setting>\r
+    <Setting Name="NativeLanguage" Type="System.String" Scope="User">\r
+      <Value Profile="(Default)">Any</Value>\r
+    </Setting>\r
+    <Setting Name="DubAudio" Type="System.Boolean" Scope="User">\r
+      <Value Profile="(Default)">False</Value>\r
+    </Setting>\r
   </Settings>\r
 </SettingsFile>
\ No newline at end of file
index 1545f33..eb64a36 100644 (file)
             <setting name="PromptOnUnmatchingQueries" serializeAs="String">\r
                 <value>True</value>\r
             </setting>\r
+            <setting name="NativeLanguage" serializeAs="String">\r
+                <value>Any</value>\r
+            </setting>\r
+            <setting name="DubAudio" serializeAs="String">\r
+                <value>False</value>\r
+            </setting>\r
         </Handbrake.Properties.Settings>\r
     </userSettings>\r
 <startup><supportedRuntime version="v2.0.50727"/></startup></configuration>\r
index 697ca26..b24ec2b 100644 (file)
@@ -61,6 +61,8 @@ namespace Handbrake
             this.label29 = new System.Windows.Forms.Label();\r
             this.btn_vlcPath = new System.Windows.Forms.Button();\r
             this.txt_vlcPath = new System.Windows.Forms.TextBox();\r
+            this.tab_audio_sub = new System.Windows.Forms.TabPage();\r
+            this.drop_preferredLang = new System.Windows.Forms.ComboBox();\r
             this.tab_cli = new System.Windows.Forms.TabPage();\r
             this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel();\r
             this.label12 = new System.Windows.Forms.Label();\r
@@ -128,11 +130,16 @@ namespace Handbrake
             this.label27 = new System.Windows.Forms.Label();\r
             this.openFile_vlc = new System.Windows.Forms.OpenFileDialog();\r
             this.tableLayoutPanel5 = new System.Windows.Forms.TableLayoutPanel();\r
+            this.label15 = new System.Windows.Forms.Label();\r
+            this.radio_dub = new System.Windows.Forms.RadioButton();\r
+            this.radio_foreignAndSubs = new System.Windows.Forms.RadioButton();\r
+            this.label31 = new System.Windows.Forms.Label();\r
             this.tab_options.SuspendLayout();\r
             this.tab_general.SuspendLayout();\r
             this.tableLayoutPanel1.SuspendLayout();\r
             this.tab_picture.SuspendLayout();\r
             this.tableLayoutPanel2.SuspendLayout();\r
+            this.tab_audio_sub.SuspendLayout();\r
             this.tab_cli.SuspendLayout();\r
             this.tableLayoutPanel3.SuspendLayout();\r
             this.tab_advanced.SuspendLayout();\r
@@ -182,6 +189,7 @@ namespace Handbrake
             this.tableLayoutPanel5.SetColumnSpan(this.tab_options, 2);\r
             this.tab_options.Controls.Add(this.tab_general);\r
             this.tab_options.Controls.Add(this.tab_picture);\r
+            this.tab_options.Controls.Add(this.tab_audio_sub);\r
             this.tab_options.Controls.Add(this.tab_cli);\r
             this.tab_options.Controls.Add(this.tab_advanced);\r
             this.tab_options.Dock = System.Windows.Forms.DockStyle.Fill;\r
@@ -522,6 +530,33 @@ namespace Handbrake
                     "ew feature.");\r
             this.txt_vlcPath.TextChanged += new System.EventHandler(this.txt_vlcPath_TextChanged);\r
             // \r
+            // tab_audio_sub\r
+            // \r
+            this.tab_audio_sub.Controls.Add(this.label31);\r
+            this.tab_audio_sub.Controls.Add(this.label15);\r
+            this.tab_audio_sub.Controls.Add(this.radio_foreignAndSubs);\r
+            this.tab_audio_sub.Controls.Add(this.drop_preferredLang);\r
+            this.tab_audio_sub.Controls.Add(this.radio_dub);\r
+            this.tab_audio_sub.Location = new System.Drawing.Point(4, 22);\r
+            this.tab_audio_sub.Name = "tab_audio_sub";\r
+            this.tab_audio_sub.Padding = new System.Windows.Forms.Padding(3);\r
+            this.tab_audio_sub.Size = new System.Drawing.Size(580, 306);\r
+            this.tab_audio_sub.TabIndex = 6;\r
+            this.tab_audio_sub.Text = "Audio / Subtitles";\r
+            this.tab_audio_sub.UseVisualStyleBackColor = true;\r
+            // \r
+            // drop_preferredLang\r
+            // \r
+            this.drop_preferredLang.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;\r
+            this.drop_preferredLang.FormattingEnabled = true;\r
+            this.drop_preferredLang.Location = new System.Drawing.Point(200, 16);\r
+            this.drop_preferredLang.Name = "drop_preferredLang";\r
+            this.drop_preferredLang.Size = new System.Drawing.Size(118, 21);\r
+            this.drop_preferredLang.TabIndex = 87;\r
+            this.ToolTip.SetToolTip(this.drop_preferredLang, "The number of processor\'s / processor cores. Unless your having problems, leave o" +\r
+                    "n Automatic.");\r
+            this.drop_preferredLang.SelectedIndexChanged += new System.EventHandler(this.drop_preferredLang_SelectedIndexChanged);\r
+            // \r
             // tab_cli\r
             // \r
             this.tab_cli.Controls.Add(this.tableLayoutPanel3);\r
@@ -1421,6 +1456,51 @@ namespace Handbrake
             this.tableLayoutPanel5.Size = new System.Drawing.Size(594, 405);\r
             this.tableLayoutPanel5.TabIndex = 62;\r
             // \r
+            // label15\r
+            // \r
+            this.label15.AutoSize = true;\r
+            this.label15.Location = new System.Drawing.Point(87, 19);\r
+            this.label15.Name = "label15";\r
+            this.label15.Size = new System.Drawing.Size(107, 13);\r
+            this.label15.TabIndex = 88;\r
+            this.label15.Text = "Preferred Language:";\r
+            // \r
+            // radio_dub\r
+            // \r
+            this.radio_dub.AutoSize = true;\r
+            this.radio_dub.Location = new System.Drawing.Point(200, 53);\r
+            this.radio_dub.Name = "radio_dub";\r
+            this.radio_dub.Size = new System.Drawing.Size(164, 17);\r
+            this.radio_dub.TabIndex = 89;\r
+            this.radio_dub.TabStop = true;\r
+            this.radio_dub.Text = "DUB Foreign Language Audio";\r
+            this.radio_dub.UseVisualStyleBackColor = true;\r
+            this.radio_dub.CheckedChanged += new System.EventHandler(this.radio_dub_CheckedChanged);\r
+            // \r
+            // radio_foreignAndSubs\r
+            // \r
+            this.radio_foreignAndSubs.AutoSize = true;\r
+            this.radio_foreignAndSubs.Location = new System.Drawing.Point(200, 76);\r
+            this.radio_foreignAndSubs.Name = "radio_foreignAndSubs";\r
+            this.radio_foreignAndSubs.Size = new System.Drawing.Size(241, 17);\r
+            this.radio_foreignAndSubs.TabIndex = 90;\r
+            this.radio_foreignAndSubs.TabStop = true;\r
+            this.radio_foreignAndSubs.Text = "Use foreign language audio and add subtitles";\r
+            this.radio_foreignAndSubs.UseVisualStyleBackColor = true;\r
+            this.radio_foreignAndSubs.CheckedChanged += new System.EventHandler(this.radio_foreignAndSubs_CheckedChanged);\r
+            // \r
+            // label31\r
+            // \r
+            this.label31.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));\r
+            this.label31.AutoSize = true;\r
+            this.label31.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
+            this.label31.Location = new System.Drawing.Point(16, 19);\r
+            this.label31.Margin = new System.Windows.Forms.Padding(3, 5, 3, 0);\r
+            this.label31.Name = "label31";\r
+            this.label31.Size = new System.Drawing.Size(52, 13);\r
+            this.label31.TabIndex = 91;\r
+            this.label31.Text = "Actions:";\r
+            // \r
             // frmOptions\r
             // \r
             this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);\r
@@ -1449,6 +1529,8 @@ namespace Handbrake
             this.tab_picture.PerformLayout();\r
             this.tableLayoutPanel2.ResumeLayout(false);\r
             this.tableLayoutPanel2.PerformLayout();\r
+            this.tab_audio_sub.ResumeLayout(false);\r
+            this.tab_audio_sub.PerformLayout();\r
             this.tab_cli.ResumeLayout(false);\r
             this.tab_cli.PerformLayout();\r
             this.tableLayoutPanel3.ResumeLayout(false);\r
@@ -1559,5 +1641,11 @@ namespace Handbrake
         private System.Windows.Forms.TableLayoutPanel tableLayoutPanel4;\r
         private System.Windows.Forms.TableLayoutPanel tableLayoutPanel5;\r
         private System.Windows.Forms.CheckBox check_promptOnUnmatchingQueries;\r
+        private System.Windows.Forms.TabPage tab_audio_sub;\r
+        internal System.Windows.Forms.ComboBox drop_preferredLang;\r
+        private System.Windows.Forms.Label label31;\r
+        private System.Windows.Forms.RadioButton radio_foreignAndSubs;\r
+        private System.Windows.Forms.RadioButton radio_dub;\r
+        private System.Windows.Forms.Label label15;\r
     }\r
 }
\ No newline at end of file
index 174b860..66adf04 100644 (file)
@@ -5,6 +5,7 @@
           It may be used under the terms of the GNU General Public License. */\r
 \r
 using System;\r
+using System.Collections.Generic;\r
 using System.Globalization;\r
 using System.Windows.Forms;\r
 using Handbrake.Functions;\r
@@ -16,6 +17,9 @@ namespace Handbrake
         public frmOptions()\r
         {\r
             InitializeComponent();\r
+            IDictionary<string, string> langList = Main.mapLanguages();\r
+            foreach (string item in langList.Keys)\r
+                drop_preferredLang.Items.Add(item);\r
 \r
             // #############################\r
             // General\r
@@ -63,6 +67,18 @@ namespace Handbrake
             txt_vlcPath.Text = Properties.Settings.Default.VLC_Path;\r
 \r
             // #############################\r
+            // Audio and Subtitles Tab\r
+            // #############################\r
+\r
+            drop_preferredLang.SelectedItem = Properties.Settings.Default.NativeLanguage;\r
+\r
+            if (Properties.Settings.Default.DubAudio)\r
+                radio_dub.Checked = true;\r
+            else\r
+                radio_foreignAndSubs.Checked = true;\r
+\r
+\r
+            // #############################\r
             // CLI\r
             // #############################\r
 \r
@@ -212,6 +228,23 @@ namespace Handbrake
         }\r
         #endregion\r
 \r
+        #region Audio and Subtitles\r
+        private void drop_preferredLang_SelectedIndexChanged(object sender, EventArgs e)\r
+        {\r
+            Properties.Settings.Default.NativeLanguage = drop_preferredLang.SelectedItem.ToString();\r
+        }\r
+        private void radio_dub_CheckedChanged(object sender, EventArgs e)\r
+        {\r
+            if (radio_dub.Checked)\r
+                Properties.Settings.Default.DubAudio = true;\r
+        }\r
+        private void radio_foreignAndSubs_CheckedChanged(object sender, EventArgs e)\r
+        {\r
+            if (radio_foreignAndSubs.Checked)\r
+                Properties.Settings.Default.DubAudio = false;\r
+        }       \r
+        #endregion\r
+\r
         #region CLI\r
         private void check_cli_minimized_CheckedChanged(object sender, EventArgs e)\r
         {\r
@@ -362,5 +395,6 @@ namespace Handbrake
             Properties.Settings.Default.Save(); // Small hack for Vista. Seems to work fine on XP without this\r
             this.Close();\r
         }\r
+\r
     }\r
 }
\ No newline at end of file
index 139d824..427cdd9 100644 (file)
   <metadata name="ToolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">\r
     <value>132, 18</value>\r
   </metadata>\r
+  <metadata name="ToolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">\r
+    <value>132, 18</value>\r
+  </metadata>\r
   <metadata name="pathFinder.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">\r
     <value>17, 17</value>\r
   </metadata>\r