From 6bba9fb04f98193e1a4114a18e85fceb9a940f4e Mon Sep 17 00:00:00 2001 From: RKrom Date: Thu, 26 Jun 2014 08:49:53 +0200 Subject: [PATCH] When having maintain aspect ratio deselected, the size was not correctly transported from the settings to the rescale code. --- Greenshot/Forms/ResizeSettingsForm.cs | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/Greenshot/Forms/ResizeSettingsForm.cs b/Greenshot/Forms/ResizeSettingsForm.cs index fe3352071..2e5c24ace 100644 --- a/Greenshot/Forms/ResizeSettingsForm.cs +++ b/Greenshot/Forms/ResizeSettingsForm.cs @@ -104,14 +104,19 @@ namespace Greenshot.Forms { if (!validate(sender)) { return; } - if (!checkbox_aspectratio.Checked) { - return; - } TextBox textbox = sender as TextBox; if (textbox.Text.Length == 0) { return; } - bool isWidth = textbox == textbox_width; + bool isWidth = textbox == textbox_width; + if (!checkbox_aspectratio.Checked) { + if (isWidth) { + newWidth = double.Parse(textbox_width.Text); + } else { + newHeight = double.Parse(textbox_height.Text); + } + return; + } bool isPercent = false; if (isWidth) { isPercent = value_percent.Equals(combobox_width.SelectedItem);