From 7f3a75872a71513a8331d480dc920a515aaf91a7 Mon Sep 17 00:00:00 2001 From: sr55 Date: Tue, 3 Nov 2009 16:17:14 +0000 Subject: WinGui: - Fix issue with weightb option on the x264 panel. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2912 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- win/C#/Controls/x264Panel.cs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'win/C#/Controls') diff --git a/win/C#/Controls/x264Panel.cs b/win/C#/Controls/x264Panel.cs index 6df49e744..4229c8298 100644 --- a/win/C#/Controls/x264Panel.cs +++ b/win/C#/Controls/x264Panel.cs @@ -349,7 +349,10 @@ namespace Handbrake.Controls drop_adaptBFrames.SelectedIndex = (badapt + 1); continue; case "weightb": - check_weightedBFrames.CheckState = CheckState.Checked; + if (optValue != "0") + check_weightedBFrames.CheckState = CheckState.Checked; + else + check_weightedBFrames.CheckState = CheckState.Unchecked; continue; case "b-pyramid": check_pyrmidalBFrames.CheckState = CheckState.Checked; @@ -521,7 +524,7 @@ namespace Handbrake.Controls else if (optNameToChange.Equals("mixed-refs")) thisOpt = check_mixedReferences.CheckState == CheckState.Checked ? "mixed-refs=1" : "mixed-refs=0"; else if (optNameToChange.Equals("weightb")) - thisOpt = check_weightedBFrames.CheckState == CheckState.Checked ? "weightb=1" : ""; + thisOpt = check_weightedBFrames.CheckState == CheckState.Checked ? "" : "weightb=0"; else if (optNameToChange.Equals("b-pyramid")) thisOpt = check_pyrmidalBFrames.CheckState == CheckState.Checked ? "b-pyramid=1" : ""; else if (optNameToChange.Equals("no-fast-pskip")) @@ -791,8 +794,8 @@ namespace Handbrake.Controls } else if (optNameToChange.Equals("weightb")) { - if (check_weightedBFrames.CheckState == CheckState.Checked) - query = query + colon + "weightb=1"; + if (check_weightedBFrames.CheckState != CheckState.Checked) + query = query + colon + "weightb=0"; } else if (optNameToChange.Equals("b-pyramid")) { -- cgit v1.2.3