mirror of
https://github.com/tdlight-team/tdlight-telegram-bot-api.git
synced 2024-12-26 12:45:52 +01:00
Add fields chat.profile_accent_color_id and chat.profile_background_custom_emoji_id.
This commit is contained in:
parent
7d84c0a0d8
commit
7575257ca6
@ -1011,6 +1011,12 @@ class Client::JsonChat final : public td::Jsonable {
|
||||
if (chat_info->background_custom_emoji_id != 0) {
|
||||
object("background_custom_emoji_id", td::to_string(chat_info->background_custom_emoji_id));
|
||||
}
|
||||
if (chat_info->profile_accent_color_id != -1) {
|
||||
object("profile_accent_color_id", chat_info->profile_accent_color_id);
|
||||
}
|
||||
if (chat_info->profile_background_custom_emoji_id != 0) {
|
||||
object("profile_background_custom_emoji_id", td::to_string(chat_info->profile_background_custom_emoji_id));
|
||||
}
|
||||
if (chat_info->has_protected_content) {
|
||||
object("has_protected_content", td::JsonTrue());
|
||||
}
|
||||
@ -6557,6 +6563,8 @@ void Client::on_update(object_ptr<td_api::Object> result) {
|
||||
}
|
||||
chat_info->accent_color_id = chat->accent_color_id_;
|
||||
chat_info->background_custom_emoji_id = chat->background_custom_emoji_id_;
|
||||
chat_info->profile_accent_color_id = chat->profile_accent_color_id_;
|
||||
chat_info->profile_background_custom_emoji_id = chat->profile_background_custom_emoji_id_;
|
||||
chat_info->has_protected_content = chat->has_protected_content_;
|
||||
break;
|
||||
}
|
||||
@ -6606,6 +6614,8 @@ void Client::on_update(object_ptr<td_api::Object> result) {
|
||||
CHECK(chat_info->type != ChatInfo::Type::Unknown);
|
||||
chat_info->accent_color_id = update->accent_color_id_;
|
||||
chat_info->background_custom_emoji_id = update->background_custom_emoji_id_;
|
||||
chat_info->profile_accent_color_id = update->profile_accent_color_id_;
|
||||
chat_info->profile_background_custom_emoji_id = update->profile_background_custom_emoji_id_;
|
||||
break;
|
||||
}
|
||||
case td_api::updateChatHasProtectedContent::ID: {
|
||||
|
@ -940,7 +940,9 @@ class Client final : public WebhookActor::Callback {
|
||||
td::string title;
|
||||
int32 message_auto_delete_time = 0;
|
||||
int32 accent_color_id = -1;
|
||||
int32 profile_accent_color_id = -1;
|
||||
int64 background_custom_emoji_id = 0;
|
||||
int64 profile_background_custom_emoji_id = 0;
|
||||
bool has_protected_content = false;
|
||||
object_ptr<td_api::chatAvailableReactionsSome> available_reactions;
|
||||
object_ptr<td_api::chatPhotoInfo> photo_info;
|
||||
|
Loading…
Reference in New Issue
Block a user