mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-06 23:24:01 +02:00
Update API scheme on layer 152.
This commit is contained in:
parent
6bac662ee8
commit
a58f9c6ebd
5 changed files with 27 additions and 12 deletions
|
@ -74,7 +74,7 @@ inputMediaPoll#f94e5f1 flags:# poll:Poll correct_answers:flags.0?Vector<bytes> s
|
|||
inputMediaDice#e66fbf7b emoticon:string = InputMedia;
|
||||
|
||||
inputChatPhotoEmpty#1ca48f57 = InputChatPhoto;
|
||||
inputChatUploadedPhoto#c642724e flags:# file:flags.0?InputFile video:flags.1?InputFile video_start_ts:flags.2?double = InputChatPhoto;
|
||||
inputChatUploadedPhoto#bdcdaec0 flags:# file:flags.0?InputFile video:flags.1?InputFile video_start_ts:flags.2?double video_emoji_markup:flags.3?VideoSize = InputChatPhoto;
|
||||
inputChatPhoto#8953ad37 id:InputPhoto = InputChatPhoto;
|
||||
|
||||
inputGeoPointEmpty#e4c123d6 = InputGeoPoint;
|
||||
|
@ -128,7 +128,7 @@ chatForbidden#6592a1a7 id:long title:string = Chat;
|
|||
channel#83259464 flags:# creator:flags.0?true left:flags.2?true broadcast:flags.5?true verified:flags.7?true megagroup:flags.8?true restricted:flags.9?true signatures:flags.11?true min:flags.12?true scam:flags.19?true has_link:flags.20?true has_geo:flags.21?true slowmode_enabled:flags.22?true call_active:flags.23?true call_not_empty:flags.24?true fake:flags.25?true gigagroup:flags.26?true noforwards:flags.27?true join_to_send:flags.28?true join_request:flags.29?true forum:flags.30?true flags2:# id:long access_hash:flags.13?long title:string username:flags.6?string photo:ChatPhoto date:int restriction_reason:flags.9?Vector<RestrictionReason> admin_rights:flags.14?ChatAdminRights banned_rights:flags.15?ChatBannedRights default_banned_rights:flags.18?ChatBannedRights participants_count:flags.17?int usernames:flags2.0?Vector<Username> = Chat;
|
||||
channelForbidden#17d493d5 flags:# broadcast:flags.5?true megagroup:flags.8?true id:long access_hash:long title:string until_date:flags.16?int = Chat;
|
||||
|
||||
chatFull#c9d31138 flags:# can_set_username:flags.7?true has_scheduled:flags.8?true id:long about:string participants:ChatParticipants chat_photo:flags.2?Photo notify_settings:PeerNotifySettings exported_invite:flags.13?ExportedChatInvite bot_info:flags.3?Vector<BotInfo> pinned_msg_id:flags.6?int folder_id:flags.11?int call:flags.12?InputGroupCall ttl_period:flags.14?int groupcall_default_join_as:flags.15?Peer theme_emoticon:flags.16?string requests_pending:flags.17?int recent_requesters:flags.17?Vector<long> available_reactions:flags.18?ChatReactions = ChatFull;
|
||||
chatFull#c9d31138 flags:# can_set_username:flags.7?true has_scheduled:flags.8?true translations_disabled:flags.19?true id:long about:string participants:ChatParticipants chat_photo:flags.2?Photo notify_settings:PeerNotifySettings exported_invite:flags.13?ExportedChatInvite bot_info:flags.3?Vector<BotInfo> pinned_msg_id:flags.6?int folder_id:flags.11?int call:flags.12?InputGroupCall ttl_period:flags.14?int groupcall_default_join_as:flags.15?Peer theme_emoticon:flags.16?string requests_pending:flags.17?int recent_requesters:flags.17?Vector<long> available_reactions:flags.18?ChatReactions = ChatFull;
|
||||
channelFull#f2355507 flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions = ChatFull;
|
||||
|
||||
chatParticipant#c02d4007 user_id:long inviter_id:long date:int = ChatParticipant;
|
||||
|
@ -198,7 +198,7 @@ messageActionSuggestProfilePhoto#57de635e photo:Photo = MessageAction;
|
|||
messageActionAttachMenuBotAllowed#e7e75f97 = MessageAction;
|
||||
messageActionRequestedPeer#fe77345d button_id:int peer:Peer = MessageAction;
|
||||
|
||||
dialog#d58a08c6 flags:# pinned:flags.2?true unread_mark:flags.3?true translations_disabled:flags.6?true peer:Peer top_message:int read_inbox_max_id:int read_outbox_max_id:int unread_count:int unread_mentions_count:int unread_reactions_count:int notify_settings:PeerNotifySettings pts:flags.0?int draft:flags.1?DraftMessage folder_id:flags.4?int ttl_period:flags.5?int = Dialog;
|
||||
dialog#d58a08c6 flags:# pinned:flags.2?true unread_mark:flags.3?true peer:Peer top_message:int read_inbox_max_id:int read_outbox_max_id:int unread_count:int unread_mentions_count:int unread_reactions_count:int notify_settings:PeerNotifySettings pts:flags.0?int draft:flags.1?DraftMessage folder_id:flags.4?int ttl_period:flags.5?int = Dialog;
|
||||
dialogFolder#71bd134c flags:# pinned:flags.2?true folder:Folder peer:Peer top_message:int unread_muted_peers_count:int unread_unmuted_peers_count:int unread_muted_messages_count:int unread_unmuted_messages_count:int = Dialog;
|
||||
|
||||
photoEmpty#2331b22d id:long = Photo;
|
||||
|
@ -248,7 +248,7 @@ inputReportReasonFake#f5ddd6e7 = ReportReason;
|
|||
inputReportReasonIllegalDrugs#a8eb2be = ReportReason;
|
||||
inputReportReasonPersonalDetails#9ec7863d = ReportReason;
|
||||
|
||||
userFull#f8d32aed flags:# blocked:flags.0?true phone_calls_available:flags.4?true phone_calls_private:flags.5?true can_pin_message:flags.7?true has_scheduled:flags.12?true video_calls_available:flags.13?true voice_messages_forbidden:flags.20?true id:long about:flags.1?string settings:PeerSettings personal_photo:flags.21?Photo profile_photo:flags.2?Photo fallback_photo:flags.22?Photo notify_settings:PeerNotifySettings bot_info:flags.3?BotInfo pinned_msg_id:flags.6?int common_chats_count:int folder_id:flags.11?int ttl_period:flags.14?int theme_emoticon:flags.15?string private_forward_name:flags.16?string bot_group_admin_rights:flags.17?ChatAdminRights bot_broadcast_admin_rights:flags.18?ChatAdminRights premium_gifts:flags.19?Vector<PremiumGiftOption> = UserFull;
|
||||
userFull#f8d32aed flags:# blocked:flags.0?true phone_calls_available:flags.4?true phone_calls_private:flags.5?true can_pin_message:flags.7?true has_scheduled:flags.12?true video_calls_available:flags.13?true voice_messages_forbidden:flags.20?true translations_disabled:flags.23?true id:long about:flags.1?string settings:PeerSettings personal_photo:flags.21?Photo profile_photo:flags.2?Photo fallback_photo:flags.22?Photo notify_settings:PeerNotifySettings bot_info:flags.3?BotInfo pinned_msg_id:flags.6?int common_chats_count:int folder_id:flags.11?int ttl_period:flags.14?int theme_emoticon:flags.15?string private_forward_name:flags.16?string bot_group_admin_rights:flags.17?ChatAdminRights bot_broadcast_admin_rights:flags.18?ChatAdminRights premium_gifts:flags.19?Vector<PremiumGiftOption> = UserFull;
|
||||
|
||||
contact#145ade0b user_id:long mutual:Bool = Contact;
|
||||
|
||||
|
@ -1248,7 +1248,8 @@ help.promoDataEmpty#98f6ac75 expires:int = help.PromoData;
|
|||
help.promoData#8c39793f flags:# proxy:flags.0?true expires:int peer:Peer chats:Vector<Chat> users:Vector<User> psa_type:flags.1?string psa_message:flags.2?string = help.PromoData;
|
||||
|
||||
videoSize#de33b094 flags:# type:string w:int h:int size:int video_start_ts:flags.0?double = VideoSize;
|
||||
videoSizeEmojiMarkup#badb646 type:string emoji_id:long background_colors:Vector<int> = VideoSize;
|
||||
videoSizeEmojiMarkup#f85c413c emoji_id:long background_colors:Vector<int> = VideoSize;
|
||||
videoSizeStickerMarkup#da082fe stickerset:InputStickerSet sticker_id:long background_colors:Vector<int> = VideoSize;
|
||||
|
||||
statsGroupTopPoster#9d04af9b user_id:long messages:int avg_chars:int = StatsGroupTopPoster;
|
||||
|
||||
|
|
|
@ -332,7 +332,8 @@ void PeerPhoto::ready(const FullMsgId &msgId, const MTPInputFile &file) {
|
|||
MTP_flags(MTPDinputChatUploadedPhoto::Flag::f_file),
|
||||
file,
|
||||
MTPInputFile(), // video
|
||||
MTPdouble()) // video_start_ts
|
||||
MTPdouble(), // video_start_ts
|
||||
MTPVideoSize()) // video_emoji_markup
|
||||
)).done(applier).afterRequest(history->sendRequestId).send();
|
||||
} else if (const auto channel = peer->asChannel()) {
|
||||
const auto history = _session->data().history(channel);
|
||||
|
@ -342,7 +343,8 @@ void PeerPhoto::ready(const FullMsgId &msgId, const MTPInputFile &file) {
|
|||
MTP_flags(MTPDinputChatUploadedPhoto::Flag::f_file),
|
||||
file,
|
||||
MTPInputFile(), // video
|
||||
MTPdouble()) // video_start_ts
|
||||
MTPdouble(), // video_start_ts
|
||||
MTPVideoSize()) // video_emoji_markup
|
||||
)).done(applier).afterRequest(history->sendRequestId).send();
|
||||
} else if (const auto user = peer->asUser()) {
|
||||
using Flag = MTPphotos_UploadContactProfilePhoto::Flag;
|
||||
|
|
|
@ -203,6 +203,8 @@ std::vector<UnavailableReason> ExtractUnavailableReasons(
|
|||
return (data.vw().v * data.vh().v);
|
||||
}, [](const MTPDvideoSizeEmojiMarkup &) {
|
||||
return 0;
|
||||
}, [](const MTPDvideoSizeStickerMarkup &) {
|
||||
return 0;
|
||||
});
|
||||
};
|
||||
const auto thumbs = data.vvideo_thumbs();
|
||||
|
@ -2818,13 +2820,17 @@ void Session::photoApplyFields(
|
|||
return data.vsize().v ? (data.vw().v * data.vh().v) : 0;
|
||||
}, [](const MTPDvideoSizeEmojiMarkup &) {
|
||||
return 0;
|
||||
}, [](const MTPDvideoSizeStickerMarkup &) {
|
||||
return 0;
|
||||
});
|
||||
};
|
||||
const auto type = [](const MTPVideoSize &size) {
|
||||
return size.match([](const auto &data) {
|
||||
return size.match([](const MTPDvideoSize &data) {
|
||||
return data.vtype().v.isEmpty()
|
||||
? char(0)
|
||||
: data.vtype().v.front();
|
||||
}, [](const auto &) {
|
||||
return char(0);
|
||||
});
|
||||
};
|
||||
const auto result = (size == PhotoSize::Small)
|
||||
|
@ -2866,7 +2872,8 @@ void Session::photoApplyFields(
|
|||
(videoLarge
|
||||
? videoLarge->match([](const MTPDvideoSize &data) {
|
||||
return VideoStartTime(data);
|
||||
}, [](const MTPDvideoSizeEmojiMarkup &) { return 0; })
|
||||
}, [](const MTPDvideoSizeEmojiMarkup &) { return 0;
|
||||
}, [](const MTPDvideoSizeStickerMarkup &) { return 0; })
|
||||
: 0));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -119,9 +119,10 @@ void ShowGradientEditor(
|
|||
|
||||
auto content = CreateGradientEditor(
|
||||
box,
|
||||
data.documentId
|
||||
? controller->session().data().document(data.documentId)
|
||||
: nullptr,
|
||||
(data.documentId
|
||||
? controller->session().data().document(
|
||||
data.documentId).get()
|
||||
: nullptr),
|
||||
data.gradientEditorColors,
|
||||
BothWayCommunication<std::vector<QColor>>{
|
||||
state->saveRequests.events(),
|
||||
|
|
|
@ -352,6 +352,8 @@ ImageWithLocation FromVideoSize(
|
|||
};
|
||||
}, [](const MTPDvideoSizeEmojiMarkup &) {
|
||||
return ImageWithLocation();
|
||||
}, [](const MTPDvideoSizeStickerMarkup &) {
|
||||
return ImageWithLocation();
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -376,6 +378,8 @@ ImageWithLocation FromVideoSize(
|
|||
};
|
||||
}, [](const MTPDvideoSizeEmojiMarkup &) {
|
||||
return ImageWithLocation();
|
||||
}, [](const MTPDvideoSizeStickerMarkup &) {
|
||||
return ImageWithLocation();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue