mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +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.setPen(Qt::NoPen);
|
||||||
p.setBrush(st::windowBgActive);
|
p.setBrush(st::windowBgActive);
|
||||||
const auto rect = icon->rect();
|
const auto rect = icon->rect();
|
||||||
auto hq = PainterHighQualityEnabler(p);
|
{
|
||||||
p.drawEllipse(rect);
|
auto hq = PainterHighQualityEnabler(p);
|
||||||
|
p.drawEllipse(rect);
|
||||||
|
}
|
||||||
st::inviteLinkCreateIcon.paintInCenter(p, rect);
|
st::inviteLinkCreateIcon.paintInCenter(p, rect);
|
||||||
}, icon->lifetime());
|
}, icon->lifetime());
|
||||||
return result;
|
return result;
|
||||||
|
@ -701,12 +703,14 @@ void LinksController::rowPaintIcon(
|
||||||
auto p = QPainter(&icon);
|
auto p = QPainter(&icon);
|
||||||
p.setPen(Qt::NoPen);
|
p.setPen(Qt::NoPen);
|
||||||
p.setBrush(*bg);
|
p.setBrush(*bg);
|
||||||
auto hq = PainterHighQualityEnabler(p);
|
{
|
||||||
auto rect = QRect(0, 0, inner, inner);
|
auto hq = PainterHighQualityEnabler(p);
|
||||||
if (color == Color::Expiring || color == Color::ExpireSoon) {
|
auto rect = QRect(0, 0, inner, inner);
|
||||||
rect = rect.marginsRemoved({ stroke, stroke, stroke, stroke });
|
if (color == Color::Expiring || color == Color::ExpireSoon) {
|
||||||
|
rect = rect.marginsRemoved({ stroke, stroke, stroke, stroke });
|
||||||
|
}
|
||||||
|
p.drawEllipse(rect);
|
||||||
}
|
}
|
||||||
p.drawEllipse(rect);
|
|
||||||
(color == Color::Revoked
|
(color == Color::Revoked
|
||||||
? st::inviteLinkRevokedIcon
|
? st::inviteLinkRevokedIcon
|
||||||
: st::inviteLinkIcon).paintInCenter(p, { 0, 0, inner, inner });
|
: st::inviteLinkIcon).paintInCenter(p, { 0, 0, inner, inner });
|
||||||
|
|
|
@ -401,7 +401,7 @@ if customRunCommand:
|
||||||
stage('patches', """
|
stage('patches', """
|
||||||
git clone https://github.com/desktop-app/patches.git
|
git clone https://github.com/desktop-app/patches.git
|
||||||
cd patches
|
cd patches
|
||||||
git checkout 0ddad09b1e
|
git checkout 7aeeaa9f17
|
||||||
""")
|
""")
|
||||||
|
|
||||||
stage('depot_tools', """
|
stage('depot_tools', """
|
||||||
|
|
Loading…
Add table
Reference in a new issue