Commit f36a78d1 authored by Nicolas Fella's avatar Nicolas Fella

[*cloud] Don't manually close the window when finished

We listen to the window closing to cancel the job. Since we also call
close on the window when the wizard finishes this can lead to the job
being canceled instead.

We don't need to close the window ourselves since that happens
automatically on destruction

(cherry picked from commit b9e46e8a)
parent 069e40b5
......@@ -41,14 +41,7 @@ void NextcloudWizard::init(KAccountsUiPlugin::UiType type)
NextcloudController *helper = new NextcloudController(m_object);
connect(helper, &NextcloudController::wizardFinished, this, [this](const QString &username, const QString &password, const QVariantMap &data) {
QWindow *window = qobject_cast<QWindow *>(m_object->rootObject());
if (window) {
window->close();
}
m_object->deleteLater();
Q_EMIT success(username, password, data);
});
......
......@@ -39,14 +39,7 @@ void OwnCloudWizard::init(KAccountsUiPlugin::UiType type)
OwncloudController *helper = new OwncloudController(m_object);
connect(helper, &OwncloudController::wizardFinished, this, [this](const QString &username, const QString &password, const QVariantMap &data) {
QWindow *window = qobject_cast<QWindow *>(m_object->rootObject());
if (window) {
window->close();
}
m_object->deleteLater();
Q_EMIT success(username, password, data);
});
......
Markdown is supported
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