mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-18 07:07:08 +02:00
Fix "Send As" button on Retina screens.
This commit is contained in:
parent
40330afbd3
commit
7bf557971e
1 changed files with 1 additions and 2 deletions
|
@ -18,7 +18,6 @@ SendAsButton::SendAsButton(QWidget *parent, const style::SendAsButton &st)
|
|||
resize(_st.width, _st.height);
|
||||
}
|
||||
|
||||
|
||||
void SendAsButton::setUserpic(QImage userpic) {
|
||||
_userpic = std::move(userpic);
|
||||
update();
|
||||
|
@ -44,7 +43,7 @@ void SendAsButton::paintEvent(QPaintEvent *e) {
|
|||
|
||||
const auto active = _activeAnimation.value(_active ? 1. : 0.);
|
||||
if (active < 1. && !_userpic.isNull()) {
|
||||
p.drawImage(left, top, _userpic);
|
||||
p.drawImage(QRect(left, top, _st.size, _st.size), _userpic);
|
||||
}
|
||||
if (active > 0.) {
|
||||
p.setOpacity(active);
|
||||
|
|
Loading…
Add table
Reference in a new issue