2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Use circle userpics in reactions from forums.

This commit is contained in:
John Preston
2024-10-03 11:16:22 +04:00
parent b60c7e97ab
commit 7d67b3d00a
3 changed files with 19 additions and 9 deletions

View File

@@ -394,7 +394,8 @@ void PeerData::paintUserpic(
Ui::PeerUserpicView &view,
int x,
int y,
int size) const {
int size,
bool forceCircle) const {
const auto cloud = userpicCloudImage(view);
const auto ratio = style::DevicePixelRatio();
Ui::ValidateUserpicCache(
@@ -402,7 +403,7 @@ void PeerData::paintUserpic(
cloud,
cloud ? nullptr : ensureEmptyUserpic().get(),
size * ratio,
isForum());
!forceCircle && isForum());
p.drawImage(QRect(x, y, size, size), view.cached);
}