Prevent activating chats search when in Settings.

This commit is contained in:
John Preston 2022-05-24 11:12:12 +04:00
parent 59be3d746c
commit c0664d2d81

View file

@ -650,6 +650,10 @@ not_null<Ui::RpWidget*> WrapWidget::topWidget() const {
void WrapWidget::showContent(object_ptr<ContentWidget> content) {
if (auto old = std::exchange(_content, std::move(content))) {
if (Ui::InFocusChain(old)) {
// Prevent activating dialogs filter field while animating.
setFocus();
}
old->hide();
// Content destructor may invoke closeBox() that will try to