From 2979df59b97b06e0056e23bc81d30e831c3ef0ab Mon Sep 17 00:00:00 2001 From: Ivan Solovev Date: Mon, 25 Jul 2022 13:10:06 +0200 Subject: QNetworkInformation: guard deprecated method definitions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The definitions of the deprecated methods were not guarded by the QT_DEPRECATED_SINCE() check, which causes compilation errors when trying to get rid of the deprecated APIs using QT_DISABLE_DEPRECATED_BEFORE. Task-number: QTBUG-105126 Pick-to: 6.4 Change-Id: Iff7a5bbde743b4351b98c58090da44fe05c4654a Reviewed-by: MÃ¥rten Nordheim --- src/network/kernel/qnetworkinformation.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/network/kernel') diff --git a/src/network/kernel/qnetworkinformation.cpp b/src/network/kernel/qnetworkinformation.cpp index a2f00fadb4..8abd3fceeb 100644 --- a/src/network/kernel/qnetworkinformation.cpp +++ b/src/network/kernel/qnetworkinformation.cpp @@ -662,6 +662,7 @@ bool QNetworkInformation::loadBackendByName(QStringView backend) return loadedBackend && loadedBackend->backendName().compare(backend, Qt::CaseInsensitive) == 0; } +#if QT_DEPRECATED_SINCE(6,4) /*! \deprecated [6.4] Use loadBackendByName() instead. @@ -671,6 +672,7 @@ bool QNetworkInformation::load(QStringView backend) { return loadBackendByName(backend); } +#endif // QT_DEPRECATED_SINCE(6,4) /*! Load a backend which supports \a features. @@ -686,6 +688,7 @@ bool QNetworkInformation::loadBackendByFeatures(Features features) return loadedBackend && loadedBackend->supports(features); } +#if QT_DEPRECATED_SINCE(6,4) /*! \deprecated [6.4] Use loadBackendByFeatures() instead. @@ -695,6 +698,7 @@ bool QNetworkInformation::load(Features features) { return loadBackendByFeatures(features); } +#endif // QT_DEPRECATED_SINCE(6,4) /*! Returns a list of the names of all currently available backends. -- cgit v1.2.3