summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs
diff options
context:
space:
mode:
authorsr55 <[email protected]>2011-12-02 20:17:53 +0000
committersr55 <[email protected]>2011-12-02 20:17:53 +0000
commitd23ce1929a4711f9153a27f39ac30f07a1b66acd (patch)
tree67b79e33de643d150412e0a35d7fdb3ecc673145 /win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs
parentf12fe4521c0555e907caecf118b7539e03ea1b38 (diff)
WinGui: (WPF) Update with options panel with the latest WinForm changes.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4371 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs')
-rw-r--r--win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs29
1 files changed, 27 insertions, 2 deletions
diff --git a/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs
index eedd247ce..dd683b7c8 100644
--- a/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs
+++ b/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs
@@ -239,11 +239,16 @@ namespace HandBrakeWPF.ViewModels
private BindingList<string> preferredLanguages = new BindingList<string>();
/// <summary>
- /// The selected preferreed langauge.
+ /// The selected preferred langauge.
/// </summary>
private string selectedPreferredLangauge;
/// <summary>
+ /// The selected preferred subtitle language
+ /// </summary>
+ private string selectedPreferredSubtitleLangauge;
+
+ /// <summary>
/// The selected preview count.
/// </summary>
private int selectedPreviewCount;
@@ -709,6 +714,23 @@ namespace HandBrakeWPF.ViewModels
}
/// <summary>
+ /// Gets or sets SelectedPreferredSubtitleLangauge.
+ /// </summary>
+ public string SelectedPreferredSubtitleLangauge
+ {
+ get
+ {
+ return this.selectedPreferredSubtitleLangauge;
+ }
+
+ set
+ {
+ this.selectedPreferredSubtitleLangauge = value;
+ this.NotifyOfPropertyChange("SelectedPreferredSubtitleLangauge");
+ }
+ }
+
+ /// <summary>
/// Gets or sets AvailableLanguages.
/// </summary>
public BindingList<string> AvailableLanguages
@@ -1334,6 +1356,7 @@ namespace HandBrakeWPF.ViewModels
}
this.selectedPreferredLangauge = this.userSettingService.GetUserSetting<string>(UserSettingConstants.NativeLanguage) ?? string.Empty;
+ this.selectedPreferredSubtitleLangauge = this.userSettingService.GetUserSetting<string>(UserSettingConstants.NativeLanguageForSubtitles) ?? string.Empty;
this.AddAudioModeOptions.Add("None");
this.AddAudioModeOptions.Add("All Remaining Tracks");
@@ -1343,7 +1366,8 @@ namespace HandBrakeWPF.ViewModels
this.AddSubtitleModeOptions.Add("All");
this.AddSubtitleModeOptions.Add("First");
this.AddSubtitleModeOptions.Add("Selected");
- this.AddSubtitleModeOptions.Add("Preferred Only");
+ this.AddSubtitleModeOptions.Add("Prefered Only (First)");
+ this.AddSubtitleModeOptions.Add("Prefered Only (All)");
this.selectedAddAudioMode = this.userSettingService.GetUserSetting<int>(UserSettingConstants.DubModeAudio);
this.selectedAddSubtitleMode = this.userSettingService.GetUserSetting<int>(UserSettingConstants.DubModeSubtitle);
@@ -1608,6 +1632,7 @@ namespace HandBrakeWPF.ViewModels
/* Audio and Subtitles */
this.userSettingService.SetUserSetting(UserSettingConstants.NativeLanguage, this.SelectedPreferredLangauge);
+ this.userSettingService.SetUserSetting(UserSettingConstants.NativeLanguageForSubtitles, this.SelectedPreferredSubtitleLangauge);
StringCollection collection = new StringCollection();
collection.AddRange(this.SelectedLangauges.ToArray());
this.userSettingService.SetUserSetting(UserSettingConstants.SelectedLanguages, collection);