QNetworkReply: rename socketConnecting to socketStartedConnecting

From the API review.

Pick-to: 6.3
Change-Id: Ic05737db79327e7811fcd974a70914b837e06601
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
bb10
Mårten Nordheim 2022-01-25 10:44:34 +01:00
parent ec57418ecf
commit 8437c27582
9 changed files with 13 additions and 13 deletions

View File

@ -358,9 +358,9 @@ bool QHttpNetworkConnectionChannel::ensureConnection()
QHttpNetworkReply *potentialReply = connection->d_func()->predictNextRequestsReply();
if (potentialReply) {
QMetaObject::invokeMethod(potentialReply, "socketConnecting", Qt::QueuedConnection);
QMetaObject::invokeMethod(potentialReply, "socketStartedConnecting", Qt::QueuedConnection);
} else if (h2RequestsToSend.count() > 0) {
QMetaObject::invokeMethod(h2RequestsToSend.values().at(0).second, "socketConnecting", Qt::QueuedConnection);
QMetaObject::invokeMethod(h2RequestsToSend.values().at(0).second, "socketStartedConnecting", Qt::QueuedConnection);
}
#ifndef QT_NO_NETWORKPROXY

View File

@ -174,7 +174,7 @@ Q_SIGNALS:
#endif
Q_SIGNALS:
void socketConnecting();
void socketStartedConnecting();
void requestSent();
void readyRead();
void finished();

View File

@ -384,7 +384,7 @@ void QHttpThreadDelegate::startRequest()
// Don't care about ignored SSL errors for now in the synchronous HTTP case.
} else if (!synchronous) {
connect(httpReply,SIGNAL(socketConnecting()), this, SIGNAL(socketConnecting()));
connect(httpReply,SIGNAL(socketStartedConnecting()), this, SIGNAL(socketStartedConnecting()));
connect(httpReply,SIGNAL(requestSent()), this, SIGNAL(requestSent()));
connect(httpReply,SIGNAL(headerChanged()), this, SLOT(headerChangedSlot()));
connect(httpReply,SIGNAL(finished()), this, SLOT(finishedSlot()));

View File

@ -144,7 +144,7 @@ signals:
void sslConfigurationChanged(const QSslConfiguration &);
void preSharedKeyAuthenticationRequired(QSslPreSharedKeyAuthenticator *);
#endif
void socketConnecting();
void socketStartedConnecting();
void requestSent();
void downloadMetaData(const QList<QPair<QByteArray,QByteArray> > &, int, const QString &, bool,
QSharedPointer<char>, qint64, qint64, bool, bool);

View File

@ -322,7 +322,7 @@ QNetworkReplyPrivate::QNetworkReplyPrivate()
*/
/*!
\fn void QNetworkReply::socketConnecting()
\fn void QNetworkReply::socketStartedConnecting()
\since 6.3
This signal is emitted 0 or more times, when the socket
@ -339,7 +339,7 @@ QNetworkReplyPrivate::QNetworkReplyPrivate()
This signal is emitted 1 or more times when the request was
sent. Useful for custom progress or timeout handling.
\sa metaDataChanged(), socketConnecting()
\sa metaDataChanged(), socketStartedConnecting()
*/
/*!

View File

@ -154,7 +154,7 @@ public Q_SLOTS:
virtual void ignoreSslErrors();
Q_SIGNALS:
void socketConnecting();
void socketStartedConnecting();
void requestSent();
void metaDataChanged();
void finished();

View File

@ -878,8 +878,8 @@ void QNetworkReplyHttpImplPrivate::postRequest(const QNetworkRequest &newHttpReq
QObject::connect(delegate, SIGNAL(downloadFinished()),
q, SLOT(replyFinished()),
Qt::QueuedConnection);
QObject::connect(delegate, &QHttpThreadDelegate::socketConnecting,
q, &QNetworkReply::socketConnecting, Qt::QueuedConnection);
QObject::connect(delegate, &QHttpThreadDelegate::socketStartedConnecting,
q, &QNetworkReply::socketStartedConnecting, Qt::QueuedConnection);
QObject::connect(delegate, &QHttpThreadDelegate::requestSent,
q, &QNetworkReply::requestSent, Qt::QueuedConnection);
connect(delegate, &QHttpThreadDelegate::downloadMetaData, this,

View File

@ -933,7 +933,7 @@ void tst_Http2::moreActivitySignals()
QSharedPointer<QNetworkReply> reply(manager->get(request));
nRequests = 1;
connect(reply.data(), &QNetworkReply::finished, this, &tst_Http2::replyFinished);
QSignalSpy spy1(reply.data(), SIGNAL(socketConnecting()));
QSignalSpy spy1(reply.data(), SIGNAL(socketStartedConnecting()));
QSignalSpy spy2(reply.data(), SIGNAL(requestSent()));
QSignalSpy spy3(reply.data(), SIGNAL(metaDataChanged()));
// Since we're using self-signed certificates,

View File

@ -9561,7 +9561,7 @@ void tst_QNetworkReply::moreActivitySignals()
url.setPort(server.serverPort());
QNetworkRequest request(url);
QNetworkReplyPtr reply(manager.get(request));
QSignalSpy spy1(reply.data(), SIGNAL(socketConnecting()));
QSignalSpy spy1(reply.data(), SIGNAL(socketStartedConnecting()));
QSignalSpy spy2(reply.data(), SIGNAL(requestSent()));
QSignalSpy spy3(reply.data(), SIGNAL(metaDataChanged()));
QSignalSpy spy4(reply.data(), SIGNAL(finished()));
@ -9574,7 +9574,7 @@ void tst_QNetworkReply::moreActivitySignals()
spy4.wait();
QCOMPARE(spy4.count(), 1);
QVERIFY(reply->error() == QNetworkReply::NoError);
// Second request will not send socketConnecting because of keep-alive, so don't check it.
// Second request will not send socketStartedConnecting because of keep-alive, so don't check it.
QNetworkReplyPtr secondreply(manager.get(request));
QSignalSpy secondspy2(secondreply.data(), SIGNAL(requestSent()));
QSignalSpy secondspy3(secondreply.data(), SIGNAL(metaDataChanged()));