diff options
author | sr55 <[email protected]> | 2012-05-19 21:02:08 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2012-05-19 21:02:08 +0000 |
commit | a8c98d2da676d507a0754ec191d53a1122a40220 (patch) | |
tree | ae847166896db64e8e7c1d78b1962f909bc19a6c /win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs | |
parent | b5a8be6d070e651d475978e06459a1f565d855f5 (diff) |
WinGui: When Changing the output format, limit to only valid choices in the video and audio encoder dropdowns.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4688 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs')
-rw-r--r-- | win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs index 1936a9898..06bd20326 100644 --- a/win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs +++ b/win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs @@ -138,6 +138,22 @@ namespace HandBrakeWPF.ViewModels this.Task.AudioTracks.Remove(track);
}
+ /// <summary>
+ /// Trigger a Notify Property Changed on the Task to force various UI elements to update.
+ /// </summary>
+ public void RefreshTask()
+ {
+ this.NotifyOfPropertyChange(() => this.Task);
+
+ if (Task.OutputFormat == OutputFormat.Mp4)
+ {
+ foreach (AudioTrack track in this.Task.AudioTracks.Where(track => track.Encoder == AudioEncoder.ffflac || track.Encoder == AudioEncoder.Vorbis))
+ {
+ track.Encoder = AudioEncoder.ffaac;
+ }
+ }
+ }
+
#endregion
#region Implemented Interfaces
|