summaryrefslogtreecommitdiffstats
path: root/win/C#/Controls/AudioPanel.cs
diff options
context:
space:
mode:
Diffstat (limited to 'win/C#/Controls/AudioPanel.cs')
-rw-r--r--win/C#/Controls/AudioPanel.cs16
1 files changed, 16 insertions, 0 deletions
diff --git a/win/C#/Controls/AudioPanel.cs b/win/C#/Controls/AudioPanel.cs
index cca75d41a..9fa9cfde3 100644
--- a/win/C#/Controls/AudioPanel.cs
+++ b/win/C#/Controls/AudioPanel.cs
@@ -224,7 +224,23 @@ namespace Handbrake.Controls
{
case "drp_audioTrack":
if (audioList.Rows.Count != 0 && audioList.SelectedRows.Count != 0)
+ {
audioList.SelectedRows[0].Cells[1].Value = drp_audioTrack.Text;
+
+ // If the track isn't AC3, and the encoder is, change it.
+ if (audioList.SelectedRows[0].Cells[2].Value.ToString().Contains("AC3") && !audioList.SelectedRows[0].Cells[1].Value.ToString().Contains("AC3"))
+ {
+ // Switch to AAC
+ drp_audioEncoder.SelectedIndex = 0;
+ }
+
+ // If the track isn't DTS, and the encoder is, change it.
+ if (audioList.SelectedRows[0].Cells[2].Value.ToString().Contains("DTS") && !audioList.SelectedRows[0].Cells[1].Value.ToString().Contains("DTS"))
+ {
+ // Switch to AAC
+ drp_audioEncoder.SelectedIndex = 0;
+ }
+ }
break;
case "drp_audioEncoder":
SetMixDown();