Help clang-tidy knowing that frame can't be null here

This commit is contained in:
Sergio Martins
2020-06-23 17:48:22 +01:00
parent 2a33599bde
commit 3217c61713

View File

@@ -181,10 +181,13 @@ void DockWidgetBase::addDockWidgetAsTab(DockWidgetBase *other, AddingOption addi
// Doesn't have a frame yet
morphIntoFloatingWindow();
frame = this->frame();
} else {
// Doesn't happen
qWarning() << Q_FUNC_INFO << "null frame";
return;
}
}
Q_ASSERT(frame);
other->setParent(nullptr);
frame->addWidget(other, addingOption);
}