mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-16 14:17:12 +02:00
Fix invite link icons on macOS Retina.
This commit is contained in:
parent
3b4b5d3576
commit
1bfa97d4fd
2 changed files with 12 additions and 8 deletions
|
@ -251,8 +251,10 @@ not_null<Ui::SettingsButton*> AddCreateLinkButton(
|
|||
p.setPen(Qt::NoPen);
|
||||
p.setBrush(st::windowBgActive);
|
||||
const auto rect = icon->rect();
|
||||
auto hq = PainterHighQualityEnabler(p);
|
||||
p.drawEllipse(rect);
|
||||
{
|
||||
auto hq = PainterHighQualityEnabler(p);
|
||||
p.drawEllipse(rect);
|
||||
}
|
||||
st::inviteLinkCreateIcon.paintInCenter(p, rect);
|
||||
}, icon->lifetime());
|
||||
return result;
|
||||
|
@ -701,12 +703,14 @@ void LinksController::rowPaintIcon(
|
|||
auto p = QPainter(&icon);
|
||||
p.setPen(Qt::NoPen);
|
||||
p.setBrush(*bg);
|
||||
auto hq = PainterHighQualityEnabler(p);
|
||||
auto rect = QRect(0, 0, inner, inner);
|
||||
if (color == Color::Expiring || color == Color::ExpireSoon) {
|
||||
rect = rect.marginsRemoved({ stroke, stroke, stroke, stroke });
|
||||
{
|
||||
auto hq = PainterHighQualityEnabler(p);
|
||||
auto rect = QRect(0, 0, inner, inner);
|
||||
if (color == Color::Expiring || color == Color::ExpireSoon) {
|
||||
rect = rect.marginsRemoved({ stroke, stroke, stroke, stroke });
|
||||
}
|
||||
p.drawEllipse(rect);
|
||||
}
|
||||
p.drawEllipse(rect);
|
||||
(color == Color::Revoked
|
||||
? st::inviteLinkRevokedIcon
|
||||
: st::inviteLinkIcon).paintInCenter(p, { 0, 0, inner, inner });
|
||||
|
|
|
@ -401,7 +401,7 @@ if customRunCommand:
|
|||
stage('patches', """
|
||||
git clone https://github.com/desktop-app/patches.git
|
||||
cd patches
|
||||
git checkout 0ddad09b1e
|
||||
git checkout 7aeeaa9f17
|
||||
""")
|
||||
|
||||
stage('depot_tools', """
|
||||
|
|
Loading…
Add table
Reference in a new issue