diff options
author | sr55 <[email protected]> | 2009-09-08 17:32:48 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2009-09-08 17:32:48 +0000 |
commit | 5552e4ba9041e0a810fb63dd175a62de48826906 (patch) | |
tree | 07966a81d347aee550a3b6105313440f89a52f60 | |
parent | ca462aa5deeba2b4ffd1b114074d61620cd07e98 (diff) |
WinGui:
- Fixed exceptions in PictureSettings - Thanks exdeus
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2808 b64f7644-9d1e-0410-96f1-a4d463321fa5
-rw-r--r-- | win/C#/Changelog.html | 2 | ||||
-rw-r--r-- | win/C#/Controls/PictureSettings.cs | 14 |
2 files changed, 12 insertions, 4 deletions
diff --git a/win/C#/Changelog.html b/win/C#/Changelog.html index 787686c56..000b94598 100644 --- a/win/C#/Changelog.html +++ b/win/C#/Changelog.html @@ -30,6 +30,8 @@ Windows Platform Specific Changlog.<br /> - A culture issue with the Video Quality slider. Should now work correctly for systems which represent floats as 1,25 instead of 1.25<br />
- Issue with SRT filepaths not being quoted.<br />
- An issue with 8x8dct not saving correctly in presets<br />
+ - Activity log window would sometimes not display the CLI query used <br />
+ - Couple issues in the Picutre Settings code <br />
<h4>Backend / Not important changes</h4>
diff --git a/win/C#/Controls/PictureSettings.cs b/win/C#/Controls/PictureSettings.cs index 1d54c9867..eed7ba560 100644 --- a/win/C#/Controls/PictureSettings.cs +++ b/win/C#/Controls/PictureSettings.cs @@ -67,10 +67,15 @@ namespace Handbrake.Controls labelDisplaySize.Text = CalculateAnamorphicSizes().Width + "x" + CalculateAnamorphicSizes().Height;
}
- updownDisplayWidth.Value = CalculateAnamorphicSizes().Width;
+ //updownDisplayWidth.Value = CalculateAnamorphicSizes().Width;
updownParWidth.Value = _sourceTitle.ParVal.Width;
updownParHeight.Value = _sourceTitle.ParVal.Height;
- _cachedDar = (double)updownDisplayWidth.Value / (double)text_height.Value;
+ //_cachedDar = (double)updownDisplayWidth.Value / (double)text_height.Value;
+
+
+ Size croppedDar = CalculateAnamorphicSizes();
+ _cachedDar = (double) croppedDar.Width/croppedDar.Height;
+ updownDisplayWidth.Value = croppedDar.Width;
}
}
@@ -263,8 +268,9 @@ namespace Handbrake.Controls // DAR = DISPLAY WIDTH / DISPLAY HEIGHT (cache after every modification)
// Calculate new Height Value
- int modulus = 16;
- int.TryParse(drp_modulus.SelectedItem.ToString(), out modulus);
+ int modulus;
+ if(!int.TryParse(drp_modulus.SelectedItem.ToString(), out modulus))
+ modulus = 16;
int rawCalculatedHeight = (int)((int)updownDisplayWidth.Value / _cachedDar);
int modulusHeight = rawCalculatedHeight - (rawCalculatedHeight % modulus);
|