Add updateWebAppMessageSent.
This commit is contained in:
parent
c1aa1defbb
commit
07424ae14e
@ -4115,6 +4115,9 @@ updateUsersNearby users_nearby:vector<chatNearby> = Update;
|
||||
//@description The list of bots added to attach menu has changed @bots The new list of bots added to attach menu. The bots must be shown in attach menu only in private chats. The bots must not be shown on scheduled messages screen
|
||||
updateAttachMenuBots bots:vector<attachMenuBot> = Update;
|
||||
|
||||
//@description A message was sent by an opened web app, so the web app needs to be closed @web_app_launch_id Identifier of web app launch
|
||||
updateWebAppMessageSent web_app_launch_id:int64 = Update;
|
||||
|
||||
//@description The list of supported reactions has changed @reactions The new list of supported reactions
|
||||
updateReactions reactions:vector<reaction> = Update;
|
||||
|
||||
@ -4878,8 +4881,8 @@ sendWebAppData bot_user_id:int53 button_text:string data:string = Ok;
|
||||
//@reply_to_message_id Identifier of the replied message for the message sent by the web app; 0 if none
|
||||
openWebApp chat_id:int53 bot_user_id:int53 url:string from_bot_menu:Bool theme:themeParameters reply_to_message_id:int53 = WebAppInfo;
|
||||
|
||||
//@description Informs TDLib that a previously opened web app was closed @launch_id Identifier of web app launch, received from openWebApp
|
||||
closeWebApp launch_id:int64 = Ok;
|
||||
//@description Informs TDLib that a previously opened web app was closed @web_app_launch_id Identifier of web app launch, received from openWebApp
|
||||
closeWebApp web_app_launch_id:int64 = Ok;
|
||||
|
||||
//@description Sets the result of interaction with a web app and sends corresponding message on behalf of the user to the chat from which the query originated; for bots only
|
||||
//@web_app_query_id Identifier of the web app query
|
||||
|
@ -7372,7 +7372,7 @@ void Td::on_request(uint64 id, td_api::openWebApp &request) {
|
||||
void Td::on_request(uint64 id, const td_api::closeWebApp &request) {
|
||||
CHECK_IS_USER();
|
||||
CREATE_OK_REQUEST_PROMISE();
|
||||
attach_menu_manager_->close_web_view(request.launch_id_, std::move(promise));
|
||||
attach_menu_manager_->close_web_view(request.web_app_launch_id_, std::move(promise));
|
||||
}
|
||||
|
||||
void Td::on_request(uint64 id, td_api::answerWebAppQuery &request) {
|
||||
|
@ -2729,6 +2729,11 @@ void UpdatesManager::on_update(tl_object_ptr<telegram_api::updateAttachMenuBots>
|
||||
td_->attach_menu_manager_->reload_attach_menu_bots(std::move(promise));
|
||||
}
|
||||
|
||||
void UpdatesManager::on_update(tl_object_ptr<telegram_api::updateWebViewResultSent> update, Promise<Unit> &&promise) {
|
||||
td_->attach_menu_manager_->close_web_view(update->query_id_, std::move(promise));
|
||||
send_closure(G()->td(), &Td::send_update, td_api::make_object<td_api::updateWebAppMessageSent>(update->query_id_));
|
||||
}
|
||||
|
||||
void UpdatesManager::on_update(tl_object_ptr<telegram_api::updateFolderPeers> update, Promise<Unit> &&promise) {
|
||||
for (auto &folder_peer : update->folder_peers_) {
|
||||
DialogId dialog_id(folder_peer->peer_);
|
||||
@ -3310,10 +3315,6 @@ void UpdatesManager::on_update(tl_object_ptr<telegram_api::updatePendingJoinRequ
|
||||
promise.set_value(Unit());
|
||||
}
|
||||
|
||||
void UpdatesManager::on_update(tl_object_ptr<telegram_api::updateWebViewResultSent> update, Promise<Unit> &&promise) {
|
||||
promise.set_value(Unit());
|
||||
}
|
||||
|
||||
void UpdatesManager::on_update(tl_object_ptr<telegram_api::updateSavedRingtones> update, Promise<Unit> &&promise) {
|
||||
promise.set_value(Unit());
|
||||
}
|
||||
|
@ -388,6 +388,7 @@ class UpdatesManager final : public Actor {
|
||||
void on_update(tl_object_ptr<telegram_api::updateMessageReactions> update, Promise<Unit> &&promise);
|
||||
|
||||
void on_update(tl_object_ptr<telegram_api::updateAttachMenuBots> update, Promise<Unit> &&promise);
|
||||
void on_update(tl_object_ptr<telegram_api::updateWebViewResultSent> update, Promise<Unit> &&promise);
|
||||
|
||||
void on_update(tl_object_ptr<telegram_api::updateFolderPeers> update, Promise<Unit> &&promise);
|
||||
|
||||
@ -509,8 +510,6 @@ class UpdatesManager final : public Actor {
|
||||
|
||||
void on_update(tl_object_ptr<telegram_api::updatePendingJoinRequests> update, Promise<Unit> &&promise);
|
||||
|
||||
void on_update(tl_object_ptr<telegram_api::updateWebViewResultSent> update, Promise<Unit> &&promise);
|
||||
|
||||
void on_update(tl_object_ptr<telegram_api::updateSavedRingtones> update, Promise<Unit> &&promise);
|
||||
|
||||
// unsupported updates
|
||||
|
Loading…
x
Reference in New Issue
Block a user