mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-14 13:17:08 +02:00
Added attention style to menu item to delete chats filter.
This commit is contained in:
parent
3e89910749
commit
3f3143514e
2 changed files with 14 additions and 8 deletions
|
@ -86,10 +86,12 @@ void ShowMenu(
|
|||
auto showRemoveBox = [=] {
|
||||
state->removeApi.request(Ui::MakeWeak(parent), controller, id);
|
||||
};
|
||||
addAction(
|
||||
tr::lng_filters_context_remove(tr::now),
|
||||
std::move(showRemoveBox),
|
||||
&st::menuIconDelete);
|
||||
addAction({
|
||||
.text = tr::lng_filters_context_remove(tr::now),
|
||||
.handler = std::move(showRemoveBox),
|
||||
.icon = &st::menuIconDeleteAttention,
|
||||
.isAttention = true,
|
||||
});
|
||||
} else {
|
||||
auto customUnreadState = [=] {
|
||||
return Data::MainListMapUnreadState(
|
||||
|
|
|
@ -378,10 +378,14 @@ void FiltersMenu::showMenu(QPoint position, FilterId id) {
|
|||
std::move(filteredChats),
|
||||
addAction);
|
||||
|
||||
addAction(
|
||||
tr::lng_filters_context_remove(tr::now),
|
||||
[=] { _removeApi.request(Ui::MakeWeak(&_outer), _session, id); },
|
||||
&st::menuIconDelete);
|
||||
addAction({
|
||||
.text = tr::lng_filters_context_remove(tr::now),
|
||||
.handler = [=, this] {
|
||||
_removeApi.request(Ui::MakeWeak(&_outer), _session, id);
|
||||
},
|
||||
.icon = &st::menuIconDeleteAttention,
|
||||
.isAttention = true,
|
||||
});
|
||||
} else {
|
||||
auto customUnreadState = [=] {
|
||||
const auto session = &_session->session();
|
||||
|
|
Loading…
Add table
Reference in a new issue