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:
AlexeyZavar
2024-04-01 23:56:12 +03:00
511 changed files with 21299 additions and 4877 deletions
@@ -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);