mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-08-01 17:57:51 +00:00
Merge tag 'v4.16.0' into dev
# Conflicts: # README.md # Telegram/Resources/winrc/Telegram.rc # Telegram/Resources/winrc/Updater.rc # Telegram/SourceFiles/calls/calls_call.cpp # Telegram/SourceFiles/core/local_url_handlers.cpp # Telegram/SourceFiles/core/version.h # Telegram/SourceFiles/history/view/media/history_view_giveaway.cpp # Telegram/SourceFiles/history/view/media/history_view_sticker.cpp # Telegram/lib_ui # snap/snapcraft.yaml
This commit is contained in:
@@ -733,8 +733,11 @@ void Notification::prepareActionsCache() {
|
||||
auto replyRight = _replyPadding - st::notifyBorderWidth;
|
||||
auto actionsCacheWidth = _reply->width() + replyRight + fadeWidth;
|
||||
auto actionsCacheHeight = height() - actionsTop - st::notifyBorderWidth;
|
||||
auto actionsCacheImg = QImage(QSize(actionsCacheWidth, actionsCacheHeight) * cIntRetinaFactor(), QImage::Format_ARGB32_Premultiplied);
|
||||
actionsCacheImg.setDevicePixelRatio(cRetinaFactor());
|
||||
auto actionsCacheImg = QImage(
|
||||
QSize(actionsCacheWidth, actionsCacheHeight)
|
||||
* style::DevicePixelRatio(),
|
||||
QImage::Format_ARGB32_Premultiplied);
|
||||
actionsCacheImg.setDevicePixelRatio(style::DevicePixelRatio());
|
||||
actionsCacheImg.fill(Qt::transparent);
|
||||
{
|
||||
Painter p(&actionsCacheImg);
|
||||
@@ -876,8 +879,10 @@ void Notification::updateNotifyDisplay() {
|
||||
_hideReplyButton = options.hideReplyButton;
|
||||
|
||||
int32 w = width(), h = height();
|
||||
QImage img(w * cIntRetinaFactor(), h * cIntRetinaFactor(), QImage::Format_ARGB32_Premultiplied);
|
||||
img.setDevicePixelRatio(cRetinaFactor());
|
||||
auto img = QImage(
|
||||
size() * style::DevicePixelRatio(),
|
||||
QImage::Format_ARGB32_Premultiplied);
|
||||
img.setDevicePixelRatio(style::DevicePixelRatio());
|
||||
img.fill(st::notificationBg->c);
|
||||
|
||||
{
|
||||
@@ -911,7 +916,8 @@ void Notification::updateNotifyDisplay() {
|
||||
if (!options.hideNameAndPhoto) {
|
||||
if (_fromScheduled) {
|
||||
static const auto emoji = Ui::Emoji::Find(QString::fromUtf8("\xF0\x9F\x93\x85"));
|
||||
const auto size = Ui::Emoji::GetSizeNormal() / cIntRetinaFactor();
|
||||
const auto size = Ui::Emoji::GetSizeNormal()
|
||||
/ style::DevicePixelRatio();
|
||||
const auto top = rectForName.top() + (st::semiboldFont->height - size) / 2;
|
||||
Ui::Emoji::Draw(p, emoji, Ui::Emoji::GetSizeNormal(), rectForName.left(), top);
|
||||
rectForName.setLeft(rectForName.left() + size + st::semiboldFont->spacew);
|
||||
|
||||
Reference in New Issue
Block a user