summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsr55 <[email protected]>2012-01-25 20:02:54 +0000
committersr55 <[email protected]>2012-01-25 20:02:54 +0000
commitd727d40b8c0d982a5275627aee84782dccf5a3b7 (patch)
treef5a36ce137d8345b676ee69602e5f9a7194fc82c
parent622608df8fcda1f5c7ae0425ec86cdfeefdd61d3 (diff)
WinGui: Fix for the Encode Quality type mode not being set correctly.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4423 b64f7644-9d1e-0410-96f1-a4d463321fa5
-rw-r--r--win/CS/Functions/PresetLoader.cs4
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs2
2 files changed, 4 insertions, 2 deletions
diff --git a/win/CS/Functions/PresetLoader.cs b/win/CS/Functions/PresetLoader.cs
index 5da368ac1..47029c935 100644
--- a/win/CS/Functions/PresetLoader.cs
+++ b/win/CS/Functions/PresetLoader.cs
@@ -233,14 +233,14 @@ namespace Handbrake.Functions
}
// Quality
- if (presetQuery.Quality != null)
+ if (presetQuery.VideoEncodeRateType == VideoEncodeRateType.ConstantQuality)
{
mainWindow.radio_cq.Checked = true;
mainWindow.slider_videoQuality.Value = QualityToSliderValue(presetQuery.VideoEncoder, presetQuery.Quality);
mainWindow.check_2PassEncode.CheckState = CheckState.Unchecked;
mainWindow.check_turbo.CheckState = CheckState.Unchecked;
}
- else if (presetQuery.VideoBitrate != null)
+ else if (presetQuery.VideoEncodeRateType == VideoEncodeRateType.AverageBitrate)
{
mainWindow.radio_avgBitrate.Checked = true;
mainWindow.text_bitrate.Text = presetQuery.VideoBitrate.ToString();
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs b/win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs
index e61db7dd7..f502b1320 100644
--- a/win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs
@@ -328,6 +328,8 @@ namespace HandBrake.ApplicationServices.Utilities
{
float quality = float.Parse(videoQuality.ToString().Replace("-q ", string.Empty), Culture);
parsed.Quality = quality;
+
+ parsed.VideoEncodeRateType = VideoEncodeRateType.ConstantQuality;
}
#endregion