mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-09-01 23:25:15 +00:00
Cancel search on switching folders.
This commit is contained in:
@@ -655,6 +655,9 @@ void Widget::setupMoreChatsBar() {
|
|||||||
controller()->activeChatsFilter(
|
controller()->activeChatsFilter(
|
||||||
) | rpl::start_with_next([=](FilterId id) {
|
) | rpl::start_with_next([=](FilterId id) {
|
||||||
storiesToggleExplicitExpand(false);
|
storiesToggleExplicitExpand(false);
|
||||||
|
if (!_searchInChat) {
|
||||||
|
cancelSearch();
|
||||||
|
}
|
||||||
|
|
||||||
if (!id) {
|
if (!id) {
|
||||||
_moreChatsBar = nullptr;
|
_moreChatsBar = nullptr;
|
||||||
@@ -3345,7 +3348,7 @@ bool Widget::cancelSearch() {
|
|||||||
if (_suggestions && clearSearchFocus) {
|
if (_suggestions && clearSearchFocus) {
|
||||||
setFocus();
|
setFocus();
|
||||||
}
|
}
|
||||||
return clearingQuery || clearingInChat;
|
return clearingQuery || clearingInChat || clearSearchFocus;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Widget::cancelSearchInChat() {
|
void Widget::cancelSearchInChat() {
|
||||||
|
Reference in New Issue
Block a user