Fix possible crash in app shutdown.

This commit is contained in:
John Preston 2020-12-22 19:08:09 +04:00
parent f94280be7f
commit d7496f9824

View file

@ -1449,7 +1449,7 @@ void HistoryWidget::activate() {
updateHistoryGeometry(); updateHistoryGeometry();
} }
} }
if (App::wnd()) App::wnd()->setInnerFocus(); controller()->widget()->setInnerFocus();
} }
void HistoryWidget::setInnerFocus() { void HistoryWidget::setInnerFocus() {
@ -3347,7 +3347,7 @@ void HistoryWidget::doneShow() {
_groupCallBar->finishAnimating(); _groupCallBar->finishAnimating();
} }
checkHistoryActivation(); checkHistoryActivation();
App::wnd()->setInnerFocus(); controller()->widget()->setInnerFocus();
_preserveScrollTop = false; _preserveScrollTop = false;
} }