From b36c2befd3795caf8b54fabec67d071a5ccfd74f Mon Sep 17 00:00:00 2001 From: brianmario Date: Wed, 18 Jul 2007 19:29:07 +0000 Subject: WinGui: quick bugfix to progress bar git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@712 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- win/C#/frmReadDVD.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'win/C#/frmReadDVD.cs') diff --git a/win/C#/frmReadDVD.cs b/win/C#/frmReadDVD.cs index eaecf823f..c8103c348 100644 --- a/win/C#/frmReadDVD.cs +++ b/win/C#/frmReadDVD.cs @@ -80,7 +80,12 @@ namespace Handbrake this.BeginInvoke(new Parsing.ScanProgressEventHandler(Parser_OnScanProgress), new object[] { Sender, CurrentTitle, TitleCount }); return; } - this.scanProgress.Value = Convert.ToInt32(Convert.ToDouble(CurrentTitle) / Convert.ToDouble(TitleCount) * 100) + 1; + int progress = Convert.ToInt32(Convert.ToDouble(CurrentTitle) / Convert.ToDouble(TitleCount) * 100) + 1; + if (progress > 100) + { + progress = 100; + } + this.scanProgress.Value = progress; } } -- cgit v1.2.3