mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-06 15:13:57 +02:00
Disabled auto-closing section of scheduled messages after 'Send Now'.
This commit is contained in:
parent
3dc73417e9
commit
a6dbcdad54
2 changed files with 7 additions and 6 deletions
|
@ -420,16 +420,12 @@ bool AddSendNowMessageAction(
|
||||||
const auto itemId = item->fullId();
|
const auto itemId = item->fullId();
|
||||||
menu->addAction(tr::lng_context_send_now_msg(tr::now), [=] {
|
menu->addAction(tr::lng_context_send_now_msg(tr::now), [=] {
|
||||||
if (const auto item = owner->message(itemId)) {
|
if (const auto item = owner->message(itemId)) {
|
||||||
const auto callback = [=] {
|
|
||||||
request.navigation->showBackFromStack();
|
|
||||||
};
|
|
||||||
Window::ShowSendNowMessagesBox(
|
Window::ShowSendNowMessagesBox(
|
||||||
request.navigation,
|
request.navigation,
|
||||||
item->history(),
|
item->history(),
|
||||||
(asGroup
|
(asGroup
|
||||||
? owner->itemOrItsGroup(item)
|
? owner->itemOrItsGroup(item)
|
||||||
: MessageIdsList{ 1, itemId }),
|
: MessageIdsList{ 1, itemId }));
|
||||||
callback);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -3004,11 +3004,16 @@ void ConfirmSendNowSelectedItems(not_null<ListWidget*> widget) {
|
||||||
if (!history) {
|
if (!history) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
const auto clearSelection = [weak = Ui::MakeWeak(widget)] {
|
||||||
|
if (const auto strong = weak.data()) {
|
||||||
|
strong->cancelSelection();
|
||||||
|
}
|
||||||
|
};
|
||||||
Window::ShowSendNowMessagesBox(
|
Window::ShowSendNowMessagesBox(
|
||||||
navigation,
|
navigation,
|
||||||
history,
|
history,
|
||||||
widget->getSelectedIds(),
|
widget->getSelectedIds(),
|
||||||
[=] { navigation->showBackFromStack(); });
|
clearSelection);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString WrapBotCommandInChat(
|
QString WrapBotCommandInChat(
|
||||||
|
|
Loading…
Add table
Reference in a new issue