diff options
author | sr55 <[email protected]> | 2011-11-19 21:27:03 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2011-11-19 21:27:03 +0000 |
commit | d5844b459d902f6fc19dc13b5ab35fc48e593b95 (patch) | |
tree | 5ddd41375483a57fbd96a2d26cfdc753d7f8a78b /win/CS/Controls/AudioPanel.cs | |
parent | 3fa8817b961e616366a28a46b149375332be9123 (diff) |
WinGui: Fix a issue where audio controls would disable sometimes if there was only one audio track on the source.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4359 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/Controls/AudioPanel.cs')
-rw-r--r-- | win/CS/Controls/AudioPanel.cs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/win/CS/Controls/AudioPanel.cs b/win/CS/Controls/AudioPanel.cs index e07cf1e3a..a7728ae56 100644 --- a/win/CS/Controls/AudioPanel.cs +++ b/win/CS/Controls/AudioPanel.cs @@ -361,6 +361,8 @@ namespace Handbrake.Controls // Set the Advanced Control.
if (!advancedAudio.IsDisposed)
advancedAudio.Track = track;
+
+ this.RefreshEnabledControls();
}
}
}
@@ -587,6 +589,28 @@ namespace Handbrake.Controls #region Private Functions
/// <summary>
+ /// Refresh the enabled controls
+ /// </summary>
+ private void RefreshEnabledControls()
+ {
+ // Configure the widgets with values
+ if (drp_audioEncoder.Text.Contains("Passthru"))
+ {
+ drp_audioMix.Enabled = drp_audioBitrate.Enabled = drp_audioSample.Enabled = btn_AdvancedAudio.Enabled = false;
+ }
+ else
+ {
+ drp_audioMix.Enabled = drp_audioBitrate.Enabled = drp_audioSample.Enabled = btn_AdvancedAudio.Enabled = true;
+ }
+
+ if (drp_audioEncoder.Text.Contains("Flac"))
+ {
+ drp_audioBitrate.Enabled = false;
+ }
+ }
+
+
+ /// <summary>
/// Attempt to automatically select the correct audio tracks based on the users settings.
/// </summary>
private void AutomaticTrackSelection()
|