ToggleActionMenu::createWidget(): Do not crash if parent is not a QToolBar
requested to merge davidhurka/okular:toggleactionmenu-fix-crash-when-moving-toolbar into release/21.08
There used to be a Q_ASSERT_X that was triggered when a widget was requested with something else than a QToolBar as parent widget.
However, when the ToggleActionMenu is added to a QMenu, createWidget() is called with the QMenu as parent. This case was missed to be tested, but occurs when the toolbar is detached/moved by the user.
Fixes #62 (closed).