Don't set up DocumentationViews when shutting down
In rare situations a DocumentationView can be created when shutting
down, which can lead to race conditions and crashing. Prevent this by
returning early from the class ctor when shutdown is in progress.
In addition, prevent errors from QWidget::setTabOrder() by checking its
input arguments.
BUG: 385640