Commit 6914c813 authored by Ismael Asensio's avatar Ismael Asensio
Browse files

TabBox: Fix loading a different switcher after one has failed

We need to reset the QML Item on failure or trying to load a
different switcher afterwards will pick a wrong codepath and
also fail.

BUG: 445455
FIXED-IN: 5.25.4
parent 9e61f503
Pipeline #204728 failed with stage
in 16 minutes and 15 seconds
......@@ -88,7 +88,7 @@ private:
TabBoxHandlerPrivate::TabBoxHandlerPrivate(TabBoxHandler *q)
: m_qmlContext()
, m_qmlComponent()
, m_qmlComponent(nullptr)
, m_mainItem(nullptr)
{
this->q = q;
......@@ -289,6 +289,7 @@ QObject *TabBoxHandlerPrivate::createSwitcherItem(bool desktopMode)
"Contact your distribution about this.")
<< QStringLiteral("20");
KProcess::startDetached(QStringLiteral("kdialog"), args);
m_qmlComponent.reset(nullptr);
} else {
QObject *object = m_qmlComponent->create(m_qmlContext.data());
if (desktopMode) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment