mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Fix closing filter by escape.
This commit is contained in:
parent
5dfbec17cd
commit
7ea364e611
1 changed files with 5 additions and 2 deletions
|
@ -684,13 +684,16 @@ void Widget::animationCallback() {
|
||||||
void Widget::escape() {
|
void Widget::escape() {
|
||||||
if (controller()->openedFolder().current()) {
|
if (controller()->openedFolder().current()) {
|
||||||
controller()->closeFolder();
|
controller()->closeFolder();
|
||||||
} else if (!onCancelSearch()
|
} else if (!onCancelSearch()) {
|
||||||
|| (!_searchInChat && !App::main()->selectingPeer())) {
|
|
||||||
if (controller()->activeChatEntryCurrent().key) {
|
if (controller()->activeChatEntryCurrent().key) {
|
||||||
emit cancelled();
|
emit cancelled();
|
||||||
} else if (controller()->activeChatsFilterCurrent()) {
|
} else if (controller()->activeChatsFilterCurrent()) {
|
||||||
controller()->setActiveChatsFilter(FilterId(0));
|
controller()->setActiveChatsFilter(FilterId(0));
|
||||||
}
|
}
|
||||||
|
} else if (!_searchInChat && !App::main()->selectingPeer()) {
|
||||||
|
if (controller()->activeChatEntryCurrent().key) {
|
||||||
|
emit cancelled();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue