summary refs log tree commit diff
path: root/include/Utils.h
diff options
context:
space:
mode:
authorKonstantinos Sideris <sideris.konstantin@gmail.com>2018-02-19 23:33:11 +0200
committerKonstantinos Sideris <sideris.konstantin@gmail.com>2018-02-19 23:33:11 +0200
commit127c52e39a5455d574fcbffd75753b31897e4877 (patch)
tree16847e445836393906136dde4f5fb830034d6612 /include/Utils.h
parentMove scaleImage() in Utils (diff)
downloadnheko-127c52e39a5455d574fcbffd75753b31897e4877.tar.xz
Scale down the preview image to fit in the application window
On macOS the modal has some extra space around the main content
that might make it unusable with a big enough image.
Diffstat (limited to 'include/Utils.h')
-rw-r--r--include/Utils.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/Utils.h b/include/Utils.h

index fa825b7c..fba9bf67 100644 --- a/include/Utils.h +++ b/include/Utils.h
@@ -33,7 +33,7 @@ ImageType scaleDown(uint64_t max_width, uint64_t max_height, const ImageType &source) { if (source.isNull()) - return source; + return QPixmap(); auto width_ratio = (double)max_width / (double)source.width(); auto height_ratio = (double)max_height / (double)source.height();