Fixed image resizing with un-specified dimension

This commit is contained in:
nathan 2017-09-17 17:41:15 +02:00
parent ebf5a7981f
commit 0d73eb6b1e
1 changed files with 2 additions and 2 deletions

View File

@ -92,10 +92,10 @@ class ImageUtil {
height = originalHeight;
}
else if (width == -1) {
width = (int) (originalWidth * ratio);
width = (int) (height * ratio);
}
else if (height == -1) {
height = (int) (originalHeight / ratio);
height = (int) (width / ratio);
}