Fix a crash while updating window extents

This commit is contained in:
Ilya Fedin 2022-06-24 20:57:27 +04:00 committed by John Preston
parent 3dbf58c45f
commit c499a437f8

View file

@ -262,10 +262,10 @@ void DefaultWindowHelper::init() {
Qt::WindowStates windowState) {
if (const auto handle = window()->windowHandle()) {
handle->setFlag(Qt::FramelessWindowHint, titleShown);
updateWindowExtents();
} else {
window()->setWindowFlag(Qt::FramelessWindowHint, titleShown);
}
updateWindowExtents();
}, window()->lifetime());
window()->events() | rpl::start_with_next([=](not_null<QEvent*> e) {