mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-16 14:17:12 +02:00
Fix attach icon in theme preview.
This commit is contained in:
parent
6588242793
commit
1204e282d3
1 changed files with 7 additions and 1 deletions
|
@ -505,7 +505,13 @@ void Generator::paintComposeArea() {
|
|||
_p->fillRect(_composeArea, st::historyReplyBg[_palette]);
|
||||
|
||||
auto controlsTop = _composeArea.y() + _composeArea.height() - st::historySendSize.height();
|
||||
st::historyAttach.icon[_palette].paint(*_p, _composeArea.x() + st::historyAttach.iconPosition.x(), controlsTop + st::historyAttach.iconPosition.y(), _rect.width());
|
||||
const auto attachIconLeft = (st::historyAttach.iconPosition.x() < 0)
|
||||
? ((st::historyAttach.width - st::historyAttach.icon.width()) / 2)
|
||||
: st::historyAttach.iconPosition.x();
|
||||
const auto attachIconTop = (st::historyAttach.iconPosition.y() < 0)
|
||||
? ((st::historyAttach.height - st::historyAttach.icon.height()) / 2)
|
||||
: st::historyAttach.iconPosition.y();
|
||||
st::historyAttach.icon[_palette].paint(*_p, _composeArea.x() + attachIconLeft, controlsTop + attachIconTop, _rect.width());
|
||||
auto right = st::historySendRight + st::historySendSize.width();
|
||||
st::historyRecordVoice[_palette].paintInCenter(*_p, QRect(_composeArea.x() + _composeArea.width() - right, controlsTop, st::historySendSize.width(), st::historySendSize.height()));
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue