mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 06:35:14 +00:00
Inline switch to pm and back support added for inline bots.
This commit is contained in:
@@ -83,6 +83,14 @@ namespace App {
|
||||
box->connect(box, SIGNAL(confirmed(PeerData*)), App::main(), SLOT(onSharePhoneWithBot(PeerData*)));
|
||||
Ui::showLayer(box);
|
||||
} break;
|
||||
|
||||
case HistoryMessageReplyMarkup::Button::SwitchInline: {
|
||||
if (MainWidget *m = App::main()) {
|
||||
if (UserData *bot = msg->history()->peer->asUser()) {
|
||||
m->inlineSwitchLayer('@' + bot->username + ' ' + QString::fromUtf8(button->data));
|
||||
}
|
||||
}
|
||||
} break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -266,6 +274,12 @@ namespace Notify {
|
||||
}
|
||||
}
|
||||
|
||||
void switchInlineBotButtonReceived(const QString &query) {
|
||||
if (MainWidget *m = App::main()) {
|
||||
m->notify_switchInlineBotButtonReceived(query);
|
||||
}
|
||||
}
|
||||
|
||||
void migrateUpdated(PeerData *peer) {
|
||||
if (MainWidget *m = App::main()) m->notify_migrateUpdated(peer);
|
||||
}
|
||||
|
Reference in New Issue
Block a user