From 06b07f9eeb31be0554b4a729554ec5dee92794c4 Mon Sep 17 00:00:00 2001 From: sr55 Date: Wed, 11 Jan 2017 20:41:08 +0000 Subject: WinGui: Fix for the Queue Item Tooltip. Would erroneously display "2Pass" for CRF encodes. --- .../HandBrakeWPF/Converters/Video/VideoOptionsTooltipConverter.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'win') diff --git a/win/CS/HandBrakeWPF/Converters/Video/VideoOptionsTooltipConverter.cs b/win/CS/HandBrakeWPF/Converters/Video/VideoOptionsTooltipConverter.cs index f175ec2ad..01265f228 100644 --- a/win/CS/HandBrakeWPF/Converters/Video/VideoOptionsTooltipConverter.cs +++ b/win/CS/HandBrakeWPF/Converters/Video/VideoOptionsTooltipConverter.cs @@ -51,7 +51,13 @@ namespace HandBrakeWPF.Converters.Video string rfqp = task.VideoEncoder == VideoEncoder.X264 || task.VideoEncoder == VideoEncoder.X264_10 || task.VideoEncoder == VideoEncoder.X265 || task.VideoEncoder == VideoEncoder.X265_10 || task.VideoEncoder == VideoEncoder.X265_12 ? "RF" : "QP"; string quality = task.VideoEncodeRateType == VideoEncodeRateType.ConstantQuality ? task.Quality + rfqp : task.VideoBitrate + " kbps"; - string twoPass = task.TwoPass ? task.TurboFirstPass ? " (2-Pass with Turbo)" : " (2-Pass)" : string.Empty; + string twoPass = null; + + if (task.VideoEncodeRateType == VideoEncodeRateType.AverageBitrate) + { + twoPass = task.TwoPass ? task.TurboFirstPass ? " (2-Pass with Turbo)" : " (2-Pass)" : string.Empty; + } + return string.Format("{0} - {1}{2}", EnumHelper.GetDisplay(task.VideoEncoder), quality, twoPass); } -- cgit v1.2.3