Replace some NewClosure's with lambda connects

This commit is contained in:
Jonas Kvinge
2020-04-28 22:29:10 +02:00
parent 5ed9d9c4a0
commit 9cc6a94353
13 changed files with 33 additions and 44 deletions

View File

@@ -35,7 +35,6 @@
#include <QJsonValue>
#include <QtDebug>
#include "core/closure.h"
#include "core/logging.h"
#include "core/network.h"
#include "jsonlyricsprovider.h"
@@ -66,7 +65,7 @@ bool AuddLyricsProvider::StartSearch(const QString &artist, const QString &album
QNetworkRequest req(url);
req.setAttribute(QNetworkRequest::FollowRedirectsAttribute, true);
QNetworkReply *reply = network_->get(req);
NewClosure(reply, SIGNAL(finished()), this, SLOT(HandleSearchReply(QNetworkReply*, quint64, QString, QString)), reply, id, artist, title);
connect(reply, &QNetworkReply::finished, [=] { HandleSearchReply(reply, id, artist, title); });
//qLog(Debug) << "AudDLyrics: Sending request for" << url;