mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Version 5.10.4: Fix build with GCC.
This commit is contained in:
parent
aea90f4b65
commit
88e80b4fae
5 changed files with 9 additions and 6 deletions
|
@ -224,7 +224,6 @@ ClickHandlerPtr PremiumGift::createViewLink() {
|
||||||
return link;
|
return link;
|
||||||
}
|
}
|
||||||
const auto from = _gift->from();
|
const auto from = _gift->from();
|
||||||
const auto itemId = _parent->data()->fullId();
|
|
||||||
const auto peer = _parent->history()->peer;
|
const auto peer = _parent->history()->peer;
|
||||||
const auto date = _parent->data()->date();
|
const auto date = _parent->data()->date();
|
||||||
const auto data = *_gift->gift();
|
const auto data = *_gift->gift();
|
||||||
|
|
|
@ -457,7 +457,6 @@ auto GenerateUniqueGiftMedia(
|
||||||
st::chatUniqueTextPadding,
|
st::chatUniqueTextPadding,
|
||||||
gift->backdrop.textColor));
|
gift->backdrop.textColor));
|
||||||
|
|
||||||
const auto itemId = parent->data()->fullId();
|
|
||||||
auto link = OpenStarGiftLink(parent->data());
|
auto link = OpenStarGiftLink(parent->data());
|
||||||
push(std::make_unique<ButtonPart>(
|
push(std::make_unique<ButtonPart>(
|
||||||
tr::lng_sticker_premium_view(tr::now),
|
tr::lng_sticker_premium_view(tr::now),
|
||||||
|
|
|
@ -20,6 +20,10 @@ constexpr auto kFrameSize = 4096;
|
||||||
[[nodiscard]] QByteArray ConvertAndCut(const QByteArray &bytes) {
|
[[nodiscard]] QByteArray ConvertAndCut(const QByteArray &bytes) {
|
||||||
using namespace FFmpeg;
|
using namespace FFmpeg;
|
||||||
|
|
||||||
|
if (bytes.isEmpty()) {
|
||||||
|
return {};
|
||||||
|
}
|
||||||
|
|
||||||
auto wrap = ReadBytesWrap{
|
auto wrap = ReadBytesWrap{
|
||||||
.size = bytes.size(),
|
.size = bytes.size(),
|
||||||
.data = reinterpret_cast<const uchar*>(bytes.constData()),
|
.data = reinterpret_cast<const uchar*>(bytes.constData()),
|
||||||
|
@ -322,7 +326,7 @@ LocalSound LocalCache::sound(
|
||||||
if (!result.isEmpty()) {
|
if (!result.isEmpty()) {
|
||||||
return { id, result };
|
return { id, result };
|
||||||
}
|
}
|
||||||
result = resolveOriginalBytes();
|
result = ConvertAndCut(resolveOriginalBytes());
|
||||||
return !result.isEmpty()
|
return !result.isEmpty()
|
||||||
? LocalSound{ id, result }
|
? LocalSound{ id, result }
|
||||||
: fallbackOriginalBytes
|
: fallbackOriginalBytes
|
||||||
|
|
|
@ -772,6 +772,7 @@ void Manager::Private::showNotification(
|
||||||
NotificationInfo &&info,
|
NotificationInfo &&info,
|
||||||
Ui::PeerUserpicView &userpicView) {
|
Ui::PeerUserpicView &userpicView) {
|
||||||
const auto peer = info.peer;
|
const auto peer = info.peer;
|
||||||
|
const auto options = info.options;
|
||||||
const auto key = ContextId{
|
const auto key = ContextId{
|
||||||
.sessionId = peer->session().uniqueId(),
|
.sessionId = peer->session().uniqueId(),
|
||||||
.peerId = peer->id,
|
.peerId = peer->id,
|
||||||
|
@ -797,7 +798,7 @@ void Manager::Private::showNotification(
|
||||||
|
|
||||||
auto i = _notifications.find(key);
|
auto i = _notifications.find(key);
|
||||||
if (i != end(_notifications)) {
|
if (i != end(_notifications)) {
|
||||||
auto j = i->second.find(msgId);
|
auto j = i->second.find(info.itemId);
|
||||||
if (j != end(i->second)) {
|
if (j != end(i->second)) {
|
||||||
auto oldNotification = std::move(j->second);
|
auto oldNotification = std::move(j->second);
|
||||||
i->second.erase(j);
|
i->second.erase(j);
|
||||||
|
@ -811,7 +812,7 @@ void Manager::Private::showNotification(
|
||||||
base::flat_map<MsgId, Notification>()).first;
|
base::flat_map<MsgId, Notification>()).first;
|
||||||
}
|
}
|
||||||
const auto j = i->second.emplace(
|
const auto j = i->second.emplace(
|
||||||
msgId,
|
info.itemId,
|
||||||
std::move(notification)).first;
|
std::move(notification)).first;
|
||||||
j->second->show();
|
j->second->show();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 5fbb38cf872f2132b1ad0a564083c498e6cc6f14
|
Subproject commit e6e1cb7436262dba90e4764615e998f19d662443
|
Loading…
Add table
Reference in a new issue