Full support and build fix.

This commit is contained in:
John Preston
2025-12-18 22:25:12 +04:00
parent 53324d5494
commit 28434f4bee
136 changed files with 681 additions and 692 deletions

View File

@@ -970,7 +970,7 @@ void Uploader::uploadCoverAsPhoto(
_api->request(MTPmessages_UploadMedia(
MTP_flags(0),
MTPstring(), // business_connection_id
session().data().peer(videoId.peer)->input,
session().data().peer(videoId.peer)->input(),
MTP_inputMediaUploadedPhoto(
MTP_flags(0),
cover.info.file,

View File

@@ -190,7 +190,7 @@ void writePeer(QDataStream &stream, not_null<PeerData*> peer) {
} else if (const auto channel = peer->asChannel()) {
stream
<< channel->name()
<< quint64(channel->access)
<< quint64(channel->accessHash())
<< qint32(channel->date)
<< qint32(0) // legacy - version
<< qint32(0)
@@ -298,14 +298,6 @@ PeerData *readPeer(
if (!inlinePlaceholder.isEmpty() && user->isBot()) {
user->botInfo->inlinePlaceholder = inlinePlaceholder;
}
if (user->id == selfId) {
user->input = MTP_inputPeerSelf();
user->inputUser = MTP_inputUserSelf();
} else {
user->input = MTP_inputPeerUser(MTP_long(peerToUser(user->id).bare), MTP_long(user->accessHash()));
user->inputUser = MTP_inputUser(MTP_long(peerToUser(user->id).bare), MTP_long(user->accessHash()));
}
}
} else if (const auto chat = result->asChat()) {
QString name, inviteLink;
@@ -373,8 +365,6 @@ PeerData *readPeer(
chat->creator = creator;
chat->setInviteLink(inviteLink);
chat->input = MTP_inputPeerChat(MTP_long(peerToChat(chat->id).bare));
}
} else if (const auto channel = result->asChannel()) {
QString name, inviteLink;
@@ -394,7 +384,7 @@ PeerData *readPeer(
if (apply) {
channel->setName(name, QString());
channel->access = access;
channel->setAccessHash(access);
channel->date = date;
if (streamAppVersion >= 2008007) {
@@ -440,9 +430,6 @@ PeerData *readPeer(
}
channel->setInviteLink(inviteLink);
channel->input = MTP_inputPeerChannel(MTP_long(peerToChannel(channel->id).bare), MTP_long(access));
channel->inputChannel = MTP_inputChannel(MTP_long(peerToChannel(channel->id).bare), MTP_long(access));
}
}
if (apply) {

View File

@@ -2966,7 +2966,7 @@ void Account::writeExportSettings(const Export::Settings &settings) {
<< quint32(settings.format)
<< settings.path
<< quint32(settings.availableAt);
settings.singlePeer.match([&](const MTPDinputPeerUser & user) {
settings.singlePeer.match([&](const MTPDinputPeerUser &user) {
data.stream
<< kSinglePeerTypeUser
<< quint64(user.vuser_id().v)