From 87bfb4497ba4a0cfdb782bad932998f3dfbd319b Mon Sep 17 00:00:00 2001 From: Andrij Abyzov Date: Sun, 28 Aug 2016 00:30:03 +0200 Subject: Fix an issue applying audio codec settings from the defaults which are different from the current preset. --- win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'win/CS/HandBrakeWPF') diff --git a/win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs index 7c7c3df3c..232ed3567 100644 --- a/win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs +++ b/win/CS/HandBrakeWPF/ViewModels/AudioViewModel.cs @@ -332,17 +332,17 @@ namespace HandBrakeWPF.ViewModels return; } - switch (this.AudioDefaultsViewModel.AudioBehaviours.SelectedTrackDefaultBehaviour) + switch (this.AudioBehaviours.SelectedTrackDefaultBehaviour) { case AudioTrackDefaultsMode.None: this.Task.AudioTracks.Add(new AudioTrack { ScannedTrack = track }); break; case AudioTrackDefaultsMode.FirstTrack: - AudioBehaviourTrack template = this.currentPreset.AudioTrackBehaviours.BehaviourTracks.FirstOrDefault(); + AudioBehaviourTrack template = this.AudioBehaviours.BehaviourTracks.FirstOrDefault(); this.Task.AudioTracks.Add(template != null ? new AudioTrack(template) { ScannedTrack = track } : new AudioTrack { ScannedTrack = track }); break; case AudioTrackDefaultsMode.AllTracks: - foreach (AudioBehaviourTrack tmpl in this.currentPreset.AudioTrackBehaviours.BehaviourTracks) + foreach (AudioBehaviourTrack tmpl in this.AudioBehaviours.BehaviourTracks) { this.Task.AudioTracks.Add(tmpl != null ? new AudioTrack(tmpl) { ScannedTrack = track } : new AudioTrack { ScannedTrack = track }); } @@ -400,7 +400,7 @@ namespace HandBrakeWPF.ViewModels } // Step 4, Handle the default selection behaviour. - switch (this.AudioDefaultsViewModel.AudioBehaviours.SelectedBehaviour) + switch (this.AudioBehaviours.SelectedBehaviour) { case AudioBehaviourModes.None: this.Task.AudioTracks.Clear(); @@ -472,9 +472,9 @@ namespace HandBrakeWPF.ViewModels // The first track in the selected languages list is considered the preferred language. // So, try match tracks on this. IEnumerable