mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-01-10 08:51:12 +00:00
Merge branch 'dev' of https://github.com/telegramdesktop/tdesktop into dev
This commit is contained in:
commit
eb939fa4b0
@ -61,9 +61,10 @@ void PhotoCropBox::init(const QImage &img, PeerData *peer) {
|
||||
}
|
||||
|
||||
int32 s = st::boxWideWidth - st::boxPhotoPadding.left() - st::boxPhotoPadding.right();
|
||||
_thumb = App::pixmapFromImageInPlace(img.scaled(s, s, Qt::KeepAspectRatio, Qt::SmoothTransformation));
|
||||
_thumbw = _thumb.width();
|
||||
_thumbh = _thumb.height();
|
||||
_thumb = App::pixmapFromImageInPlace(img.scaled(s * cIntRetinaFactor(), s * cIntRetinaFactor(), Qt::KeepAspectRatio, Qt::SmoothTransformation));
|
||||
_thumb.setDevicePixelRatio(cRetinaFactor());
|
||||
_thumbw = _thumb.width() / cIntRetinaFactor();
|
||||
_thumbh = _thumb.height() / cIntRetinaFactor();
|
||||
if (_thumbw > _thumbh) {
|
||||
_cropw = _thumbh - 20;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user