Replace all uses of devicePixelRatio with devicePixelRatioF

This commit is contained in:
Luis Ángel San Martín
2022-01-14 19:22:50 +01:00
parent 380aea2a66
commit 565bc3a5d0
5 changed files with 11 additions and 11 deletions

View File

@ -267,12 +267,12 @@ void ServerConfigDialog::generateQR(const QString &serverAddress)
if (image.isNull()) {
qrCode->setText(tr("Could not load libqrencode."));
} else {
image = image.scaled(qrCode->size() * devicePixelRatio());
image = image.scaled(qrCode->size() * devicePixelRatioF());
QPixmap pMask(image.size());
pMask.fill(QColor(66, 66, 66));
pMask.setMask(image.createMaskFromColor(Qt::white));
pMask.setDevicePixelRatio(devicePixelRatio());
pMask.setDevicePixelRatio(devicePixelRatioF());
qrCode->setPixmap(pMask);
}