mirror of
https://github.com/greenshot/greenshot
synced 2025-07-30 03:30:02 -07:00
When having maintain aspect ratio deselected, the size was not correctly transported from the settings to the rescale code.
This commit is contained in:
parent
e801c95f84
commit
6bba9fb04f
1 changed files with 9 additions and 4 deletions
|
@ -104,14 +104,19 @@ namespace Greenshot.Forms {
|
||||||
if (!validate(sender)) {
|
if (!validate(sender)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!checkbox_aspectratio.Checked) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
TextBox textbox = sender as TextBox;
|
TextBox textbox = sender as TextBox;
|
||||||
if (textbox.Text.Length == 0) {
|
if (textbox.Text.Length == 0) {
|
||||||
return;
|
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;
|
bool isPercent = false;
|
||||||
if (isWidth) {
|
if (isWidth) {
|
||||||
isPercent = value_percent.Equals(combobox_width.SelectedItem);
|
isPercent = value_percent.Equals(combobox_width.SelectedItem);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue