mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-07 07:33:52 +02:00
Fixed display of custom badge in selected messages for giveaways.
This commit is contained in:
parent
13353bb615
commit
d9d96d0a6f
1 changed files with 7 additions and 1 deletions
|
@ -514,6 +514,10 @@ void StickerWithBadgePart::paintBadge(
|
||||||
const auto inner = QRectF(rect) - Margins(half);
|
const auto inner = QRectF(rect) - Margins(half);
|
||||||
const auto radius = inner.height() / 2.;
|
const auto radius = inner.height() / 2.;
|
||||||
p.drawRoundedRect(inner, radius, radius);
|
p.drawRoundedRect(inner, radius, radius);
|
||||||
|
if (_colorOverride && context.selected()) {
|
||||||
|
p.setBrush(context.st->msgStickerOverlay());
|
||||||
|
p.drawRoundedRect(inner, radius, radius);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!_sticker.parent()->usesBubblePattern(context)) {
|
if (!_sticker.parent()->usesBubblePattern(context)) {
|
||||||
|
@ -578,7 +582,9 @@ void StickerWithBadgePart::validateBadge(
|
||||||
p.drawImage(
|
p.drawImage(
|
||||||
left,
|
left,
|
||||||
half + (inner.height() - iconHeight) / 2,
|
half + (inner.height() - iconHeight) / 2,
|
||||||
_customLeftIcon);
|
context.selected()
|
||||||
|
? Images::Colored(base::duplicate(_customLeftIcon), _badgeFg)
|
||||||
|
: _customLeftIcon);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue