Fix userpic in a notification with hidden sender.

This commit is contained in:
John Preston 2023-02-03 09:50:48 +04:00
parent 5f027d7c87
commit 762589b622

View file

@ -100,13 +100,14 @@ Manager::QueuedNotification::QueuedNotification(NotificationFields &&fields)
QPixmap Manager::hiddenUserpicPlaceholder() const {
if (_hiddenUserpicPlaceholder.isNull()) {
const auto ratio = style::DevicePixelRatio();
_hiddenUserpicPlaceholder = Ui::PixmapFromImage(
LogoNoMargin().scaled(
st::notifyPhotoSize,
st::notifyPhotoSize,
st::notifyPhotoSize * ratio,
st::notifyPhotoSize * ratio,
Qt::IgnoreAspectRatio,
Qt::SmoothTransformation));
_hiddenUserpicPlaceholder.setDevicePixelRatio(cRetinaFactor());
_hiddenUserpicPlaceholder.setDevicePixelRatio(ratio);
}
return _hiddenUserpicPlaceholder;
}