summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Rettberg2019-04-09 14:58:50 +0200
committerSimon Rettberg2019-04-09 14:58:50 +0200
commitd294855247610f3903d9db0ef7b09016010cad2b (patch)
tree376aef631a88b54af945d026c854d56acc48e9ba
parentFix layout size (diff)
downloadslxgreeter-23.tar.gz
slxgreeter-23.tar.xz
slxgreeter-23.zip
Propery scale mini iconv23
-rw-r--r--src/loginform.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/loginform.cpp b/src/loginform.cpp
index b193cb1..a7252b5 100644
--- a/src/loginform.cpp
+++ b/src/loginform.cpp
@@ -58,8 +58,7 @@ void LoginForm::initialize()
if (!size.isValid()) {
size = ui->iconLabel->maximumSize();
} else {
- QSize o(ui->iconLabel->maximumSize());
- size = QSize(qMin(size.width(), o.width()), qMin(size.height(), o.height()));
+ size = size.boundedTo(ui->iconLabel->maximumSize()).expandedTo(ui->iconLabel->minimumSize());
}
pixmap = QIcon(path).pixmap(size);
}