2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-30 22:16:14 +00:00

Fix webview switch_inline to the same chat.

This commit is contained in:
John Preston
2023-03-08 16:48:23 +04:00
parent 05ffc79539
commit de9a757e7a
6 changed files with 40 additions and 50 deletions

View File

@@ -456,14 +456,12 @@ void ActivateBotCommand(ClickHandlerContext context, int row, int column) {
return false;
}();
if (!fastSwitchDone) {
const auto botAndQuery = '@'
+ bot->username()
+ ' '
+ QString::fromUtf8(button->data);
const auto query = QString::fromUtf8(button->data);
const auto chosen = [=](not_null<Data::Thread*> thread) {
return controller->content()->inlineSwitchChosen(
return controller->switchInlineQuery(
thread,
botAndQuery);
bot,
query);
};
Window::ShowChooseRecipientBox(
controller,