Commit 6590f8d6 authored by Laurent Montel's avatar Laurent Montel 😁

Port to new connect api

parent d43eb57d
......@@ -222,7 +222,7 @@ void CollectionPathResolver::doStart()
}
job = new CollectionFetchJob(d->mCurrentNode, CollectionFetchJob::Base, this);
}
connect(job, SIGNAL(result(KJob*)), SLOT(jobResult(KJob*)));
connect(job, &CollectionFetchJob::result, this, [this, d](KJob *job) { d->jobResult(job);});
}
//@endcond
......
......@@ -383,7 +383,7 @@ void CollectionFetchJob::slotResult(KJob *job)
}
d_ptr->mCurrentSubJob = nullptr;
removeSubjob(job);
QTimer::singleShot(0, this, SLOT(startNext()));
QTimer::singleShot(0, this, [this, d]() { d->startNext(); });
} else {
Job::slotResult(job);
}
......
......@@ -312,7 +312,7 @@ bool ItemModifyJob::doHandleResponse(qint64 tag, const Protocol::CommandPtr &res
ConflictHandler *handler = new ConflictHandler(ConflictHandler::LocalLocalConflict, this);
handler->setConflictingItems(d->mItems.first(), d->mItems.first());
connect(handler, &ConflictHandler::conflictResolved, this, [this, d]() { d->conflictResolved(); });
connect(handler, SIGNAL(error(QString)), SLOT(conflictResolveError(QString)));
connect(handler, &ConflictHandler::error, this, [this, d](const QString &str) { d->conflictResolveError(str); });
#if QT_VERSION >= QT_VERSION_CHECK(5, 10, 0)
QMetaObject::invokeMethod(handler, &ConflictHandler::start, Qt::QueuedConnection);
#else
......
......@@ -204,9 +204,6 @@ protected:
private:
//@cond PRIVATE
Q_DECLARE_PRIVATE(ItemModifyJob)
Q_PRIVATE_SLOT(d_func(), void conflictResolved())
Q_PRIVATE_SLOT(d_func(), void conflictResolveError(const QString &))
//@endcond
};
......
......@@ -123,7 +123,7 @@ void RecursiveItemFetchJob::start()
job->fetchScope().setContentMimeTypes(d->mMimeTypes);
}
connect(job, SIGNAL(result(KJob*)), this, SLOT(collectionFetchResult(KJob*)));
connect(job, &CollectionFetchJob::result, this, [this](KJob *job) { d->collectionFetchResult(job); });
}
Akonadi::Item::List RecursiveItemFetchJob::items() const
......
......@@ -145,7 +145,6 @@ private:
class Private;
Private *const d;
Q_PRIVATE_SLOT(d, void collectionFetchResult(KJob *))
Q_PRIVATE_SLOT(d, void itemFetchResult(KJob *))
//@endcond
};
......
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