From 3839e65f910a7e110404e9d8cb8387366fcf0e1d Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Tue, 26 Feb 2019 18:03:29 +0100 Subject: API cleanup MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Based on review feedback Change-Id: Ide40d4fd563ea682eaa2cc457d857445adea85cd Reviewed-by: Jüri Valdmann --- src/webenginewidgets/api/qwebengineprofile.cpp | 22 +++++++--------------- 1 file changed, 7 insertions(+), 15 deletions(-) (limited to 'src/webenginewidgets/api/qwebengineprofile.cpp') diff --git a/src/webenginewidgets/api/qwebengineprofile.cpp b/src/webenginewidgets/api/qwebengineprofile.cpp index 32c000755..5b4b540cc 100644 --- a/src/webenginewidgets/api/qwebengineprofile.cpp +++ b/src/webenginewidgets/api/qwebengineprofile.cpp @@ -648,16 +648,7 @@ QWebEngineScriptCollection *QWebEngineProfile::scripts() const \since 5.13 \sa QWebEngineNotification */ -void QWebEngineProfile::setNotificationPresenter(const std::function ¬ificationPresenter) -{ - Q_D(QWebEngineProfile); - d->m_notificationPresenter = notificationPresenter; -} - -/*! - \overload -*/ -void QWebEngineProfile::setNotificationPresenter(std::function &¬ificationPresenter) +void QWebEngineProfile::setNotificationPresenter(std::function notificationPresenter) { Q_D(QWebEngineProfile); d->m_notificationPresenter = std::move(notificationPresenter); @@ -809,12 +800,13 @@ void QWebEngineProfile::removeAllUrlSchemeHandlers() /*! \since 5.13 - Sets this profile to be used for downloading and caching when needed during - certificate verification, for instance for OCSP, CRLs, and AIA. + Sets if this profile is to be used for downloading and caching when needed + during certificate verification, for instance for OCSP, CRLs, and AIA. Only one QWebEngineProfile can do this at a time, and it is recommended that the profile fullfilling this role has a disk HTTP cache to avoid - needlessly re-downloading. + needlessly re-downloading. If you set the option on a second profile, + it will be disabled on the profile it is currently set. Currently only affects Linux/NSS installations where it enables OCSP. @@ -823,10 +815,10 @@ void QWebEngineProfile::removeAllUrlSchemeHandlers() \sa isUsedForGlobalCertificateVerification(), httpCacheType() */ -void QWebEngineProfile::setUseForGlobalCertificateVerification() +void QWebEngineProfile::setUseForGlobalCertificateVerification(bool enabled) { Q_D(QWebEngineProfile); - d->profileAdapter()->setUseForGlobalCertificateVerification(); + d->profileAdapter()->setUseForGlobalCertificateVerification(enabled); } /*! -- cgit v1.2.3