summaryrefslogtreecommitdiffstats
path: root/win/CS
diff options
context:
space:
mode:
authorsr55 <[email protected]>2016-03-18 21:05:18 +0000
committersr55 <[email protected]>2016-03-18 21:05:18 +0000
commit78827728072257daadc8acb00bb24af7779c4d63 (patch)
tree7272e09caba9a598dbff72465c96da13e53a99a2 /win/CS
parentbbead11b5116a8ee8e1943ed02b9e794f56ac03e (diff)
WinGui: Fixed an issue where the " Use Advanced Tab" was not being loaded correctly with the new json presets.
Diffstat (limited to 'win/CS')
-rw-r--r--win/CS/HandBrakeWPF/ViewModels/VideoViewModel.cs18
1 files changed, 4 insertions, 14 deletions
diff --git a/win/CS/HandBrakeWPF/ViewModels/VideoViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/VideoViewModel.cs
index 25a00d822..663c8e7f7 100644
--- a/win/CS/HandBrakeWPF/ViewModels/VideoViewModel.cs
+++ b/win/CS/HandBrakeWPF/ViewModels/VideoViewModel.cs
@@ -59,7 +59,6 @@ namespace HandBrakeWPF.ViewModels
private bool showPeakFramerate;
private int rf;
private bool canClear;
- private bool useAdvancedTab;
private bool displayTurboFirstPass;
private int videoPresetMaxValue;
private int videoPresetValue;
@@ -137,24 +136,15 @@ namespace HandBrakeWPF.ViewModels
{
get
{
- return this.useAdvancedTab;
+ return this.Task.ShowAdvancedTab;
}
set
{
- if (!Equals(value, this.useAdvancedTab))
+ if (!Equals(value, this.Task.ShowAdvancedTab))
{
// Set the Advanced Tab up with the current settings, if we can.
- if (value)
- {
- this.Task.AdvancedEncoderOptions = this.GetActualx264Query();
- }
-
- if (!value)
- {
- this.Task.AdvancedEncoderOptions = string.Empty;
- }
+ this.Task.AdvancedEncoderOptions = value ? this.GetActualx264Query() : string.Empty;
- this.useAdvancedTab = value;
this.Task.ShowAdvancedTab = value;
this.NotifyOfPropertyChange(() => this.UseAdvancedTab);
}
@@ -942,7 +932,7 @@ namespace HandBrakeWPF.ViewModels
}
this.ExtraArguments = preset.Task.ExtraAdvancedArguments;
- this.UseAdvancedTab = !string.IsNullOrEmpty(preset.Task.AdvancedEncoderOptions) && this.ShowAdvancedTab;
+ this.UseAdvancedTab = (!string.IsNullOrEmpty(preset.Task.AdvancedEncoderOptions) && this.ShowAdvancedTab) || preset.Task.ShowAdvancedTab;
}
}