diff options
author | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2016-03-08 10:40:49 +0100 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2016-03-08 10:40:49 +0100 |
commit | ccf12049b662fe1b03b5b0ea199d29b32f072eda (patch) | |
tree | 43e3d0042eb1f8ba23349e10c9c7e547fab57fec /src | |
parent | 56714be7d05afb94c63b658a4fdb2bedd1bee645 (diff) | |
parent | 471d484bea6b8b84749b8d89c603cb8394f1b5ee (diff) |
Merge remote-tracking branch 'origin/5.6' into 5.7
Change-Id: Ieab3c4a6d16b1d7b7c0243ff8898f81807e7b1fc
Diffstat (limited to 'src')
-rw-r--r-- | src/core/browser_context_qt.cpp | 5 | ||||
-rw-r--r-- | src/core/browser_context_qt.h | 2 | ||||
-rw-r--r-- | src/core/config/linux.pri | 2 | ||||
-rw-r--r-- | src/core/content_browser_client_qt.cpp | 7 | ||||
-rw-r--r-- | src/core/content_main_delegate_qt.cpp | 7 | ||||
-rw-r--r-- | src/core/core_gyp_generator.pro | 2 | ||||
-rw-r--r-- | src/core/core_module.pro | 12 | ||||
-rw-r--r-- | src/core/gyp_run.pro | 13 | ||||
-rw-r--r-- | src/core/qtwebengine.gypi | 11 | ||||
-rw-r--r-- | src/core/ssl_host_state_delegate_qt.cpp | 135 | ||||
-rw-r--r-- | src/core/ssl_host_state_delegate_qt.h | 80 | ||||
-rw-r--r-- | src/webengine/api/qquickwebengineprofile.cpp | 24 | ||||
-rw-r--r-- | src/webengine/api/qquickwebenginetestsupport.cpp | 1 | ||||
-rw-r--r-- | src/webengine/doc/src/qtwebengine-platform-notes.qdoc | 3 | ||||
-rw-r--r-- | src/webenginewidgets/api/qwebengineprofile.cpp | 34 |
15 files changed, 319 insertions, 19 deletions
diff --git a/src/core/browser_context_qt.cpp b/src/core/browser_context_qt.cpp index de6c06dd7..5685c2dcd 100644 --- a/src/core/browser_context_qt.cpp +++ b/src/core/browser_context_qt.cpp @@ -44,6 +44,7 @@ #include "permission_manager_qt.h" #include "qtwebenginecoreglobal_p.h" #include "resource_context_qt.h" +#include "ssl_host_state_delegate_qt.h" #include "type_conversion.h" #include "url_request_context_getter_qt.h" @@ -172,7 +173,9 @@ content::PushMessagingService *BrowserContextQt::GetPushMessagingService() content::SSLHostStateDelegate* BrowserContextQt::GetSSLHostStateDelegate() { - return 0; + if (!sslHostStateDelegate) + sslHostStateDelegate.reset(new SSLHostStateDelegateQt(m_adapter)); + return sslHostStateDelegate.get(); } scoped_ptr<content::ZoomLevelDelegate> BrowserContextQt::CreateZoomLevelDelegate(const base::FilePath&) diff --git a/src/core/browser_context_qt.h b/src/core/browser_context_qt.h index 044a3adac..08ac05fd4 100644 --- a/src/core/browser_context_qt.h +++ b/src/core/browser_context_qt.h @@ -59,6 +59,7 @@ namespace QtWebEngineCore { class BrowserContextAdapter; class PermissionManagerQt; +class SSLHostStateDelegateQt; class URLRequestContextGetterQt; class BrowserContextQt : public content::BrowserContext @@ -104,6 +105,7 @@ private: scoped_ptr<content::ResourceContext> resourceContext; scoped_refptr<URLRequestContextGetterQt> url_request_getter_; scoped_ptr<PermissionManagerQt> permissionManager; + scoped_ptr<SSLHostStateDelegateQt> sslHostStateDelegate; BrowserContextAdapter *m_adapter; #if defined(ENABLE_SPELLCHECK) scoped_refptr<TestingPrefStore> m_prefStore; diff --git a/src/core/config/linux.pri b/src/core/config/linux.pri index 2fa6aa5c6..bd1d068d8 100644 --- a/src/core/config/linux.pri +++ b/src/core/config/linux.pri @@ -43,6 +43,6 @@ use?(system_jsoncpp): GYP_CONFIG += use_system_jsoncpp=1 use?(system_opus): GYP_CONFIG += use_system_opus=1 use?(system_snappy): GYP_CONFIG += use_system_snappy=1 use?(system_vpx): GYP_CONFIG += use_system_libvpx=1 -use?(system_icu): GYP_CONFIG += use_system_icu=1 +use?(system_icu): GYP_CONFIG += use_system_icu=1 icu_use_data_file_flag=0 use?(system_ffmpeg): GYP_CONFIG += use_system_ffmpeg=1 diff --git a/src/core/content_browser_client_qt.cpp b/src/core/content_browser_client_qt.cpp index 03d142c0b..f5f490ccf 100644 --- a/src/core/content_browser_client_qt.cpp +++ b/src/core/content_browser_client_qt.cpp @@ -423,13 +423,14 @@ void ContentBrowserClientQt::AllowCertificateError(content::WebContents *webCont const base::Callback<void(bool)>& callback, content::CertificateRequestResultType* result) { - // We leave the result with its default value. - Q_UNUSED(result); - WebContentsDelegateQt* contentsDelegate = static_cast<WebContentsDelegateQt*>(webContents->GetDelegate()); QSharedPointer<CertificateErrorController> errorController(new CertificateErrorController(new CertificateErrorControllerPrivate(cert_error, ssl_info, request_url, resource_type, overridable, strict_enforcement, callback))); contentsDelegate->allowCertificateError(errorController); + + // If we don't give the user a chance to allow it, we can reject it right away. + if (result && (!overridable || strict_enforcement)) + *result = content::CERTIFICATE_REQUEST_RESULT_TYPE_DENY; } content::LocationProvider *ContentBrowserClientQt::OverrideSystemLocationProvider() diff --git a/src/core/content_main_delegate_qt.cpp b/src/core/content_main_delegate_qt.cpp index 2f61e1e5e..0560c3f6b 100644 --- a/src/core/content_main_delegate_qt.cpp +++ b/src/core/content_main_delegate_qt.cpp @@ -97,10 +97,17 @@ content::ContentRendererClient *ContentMainDelegateQt::CreateContentRendererClie return new ContentRendererClientQt; } +// see icu_util.cc +#define ICU_UTIL_DATA_FILE 0 +#define ICU_UTIL_DATA_SHARED 1 +#define ICU_UTIL_DATA_STATIC 2 + bool ContentMainDelegateQt::BasicStartupComplete(int *exit_code) { PathService::Override(base::FILE_EXE, WebEngineLibraryInfo::getPath(base::FILE_EXE)); +#if ICU_UTIL_DATA_IMPL == ICU_UTIL_DATA_FILE PathService::Override(base::DIR_QT_LIBRARY_DATA, WebEngineLibraryInfo::getPath(base::DIR_QT_LIBRARY_DATA)); +#endif PathService::Override(content::DIR_MEDIA_LIBS, WebEngineLibraryInfo::getPath(content::DIR_MEDIA_LIBS)); PathService::Override(ui::DIR_LOCALES, WebEngineLibraryInfo::getPath(ui::DIR_LOCALES)); #if defined(ENABLE_SPELLCHECK) diff --git a/src/core/core_gyp_generator.pro b/src/core/core_gyp_generator.pro index 327ad9625..e04e34c5a 100644 --- a/src/core/core_gyp_generator.pro +++ b/src/core/core_gyp_generator.pro @@ -81,6 +81,7 @@ SOURCES = \ resource_bundle_qt.cpp \ resource_context_qt.cpp \ resource_dispatcher_host_delegate_qt.cpp \ + ssl_host_state_delegate_qt.cpp \ stream_video_node.cpp \ surface_factory_qt.cpp \ type_conversion.cpp \ @@ -160,6 +161,7 @@ HEADERS = \ renderer/web_channel_ipc_transport.h \ resource_context_qt.h \ resource_dispatcher_host_delegate_qt.h \ + ssl_host_state_delegate_qt.h \ stream_video_node.h \ surface_factory_qt.h \ type_conversion.h \ diff --git a/src/core/core_module.pro b/src/core/core_module.pro index f30af83fc..174c00afb 100644 --- a/src/core/core_module.pro +++ b/src/core/core_module.pro @@ -77,9 +77,9 @@ icu.files = $$OUT_PWD/$$getConfigDir()/icudtl.dat INSTALLS += icu locales resources } - !contains(QT_CONFIG, qt_framework): contains(QT_CONFIG, private_tests) { + !contains(QT_CONFIG, qt_framework):!force_independent { # - # Copy essential files to the qtbase build directory (for non-installed developer builds) + # Copy essential files to the qtbase build directory for non-prefix builds # icudt2build.input = icu.files @@ -97,3 +97,11 @@ icu.files = $$OUT_PWD/$$getConfigDir()/icudtl.dat QMAKE_EXTRA_COMPILERS += icudt2build resources2build } } + +OTHER_FILES = \ + $$files(../3rdparty/chromium/*.h, true) \ + $$files(../3rdparty/chromium/*.cc, true) \ + $$files(../3rdparty/chromium/*.mm, true) \ + $$files(../3rdparty/chromium/*.py, true) \ + $$files(../3rdparty/chromium/*.gyp, true) \ + $$files(../3rdparty/chromium/*.gypi, true) diff --git a/src/core/gyp_run.pro b/src/core/gyp_run.pro index e83db387b..02d1e41d6 100644 --- a/src/core/gyp_run.pro +++ b/src/core/gyp_run.pro @@ -83,9 +83,22 @@ contains(QT_ARCH, "arm") { contains(QMAKE_CFLAGS, "-mthumb"): GYP_CONFIG += arm_thumb=1 } +contains(QT_ARCH, "mips") { + !cross_compile: GYP_CONFIG += sysroot=\"\" + GYP_CONFIG += target_arch=mipsel + + contains(QMAKE_CFLAGS, "mips32r6"): mips_arch_variant=\"r6\" + else: contains(QMAKE_CFLAGS, "mips32r2"): mips_arch_variant=\"r2\" + else: contains(QMAKE_CFLAGS, "mips32"): mips_arch_variant=\"r1\" + + contains(QMAKE_CFLAGS, "-mdsp2"): GYP_CONFIG += mips_dsp_rev=2 + else: contains(QMAKE_CFLAGS, "-mdsp"): GYP_CONFIG += mips_dsp_rev=1 +} + contains(QT_ARCH, "x86_64"): GYP_CONFIG += target_arch=x64 contains(QT_ARCH, "i386"): GYP_CONFIG += target_arch=ia32 contains(QT_ARCH, "arm64"): GYP_CONFIG += target_arch=arm64 +contains(QT_ARCH, "mips64"): GYP_CONFIG += target_arch=mips64el contains(WEBENGINE_CONFIG, use_proprietary_codecs): GYP_CONFIG += proprietary_codecs=1 ffmpeg_branding=Chrome diff --git a/src/core/qtwebengine.gypi b/src/core/qtwebengine.gypi index 2ee0f3586..6cfafb0ca 100644 --- a/src/core/qtwebengine.gypi +++ b/src/core/qtwebengine.gypi @@ -133,5 +133,16 @@ 'renderer/print_web_view_helper_delegate_qt.h', ] }], + ['icu_use_data_file_flag==1', { + 'defines': ['ICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_FILE'], + }, { # else icu_use_data_file_flag !=1 + 'conditions': [ + ['OS=="win"', { + 'defines': ['ICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_SHARED'], + }, { + 'defines': ['ICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_STATIC'], + }], + ], + }], ], } diff --git a/src/core/ssl_host_state_delegate_qt.cpp b/src/core/ssl_host_state_delegate_qt.cpp new file mode 100644 index 000000000..cf17b944c --- /dev/null +++ b/src/core/ssl_host_state_delegate_qt.cpp @@ -0,0 +1,135 @@ +/**************************************************************************** +** +** Copyright (C) 2016 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtWebEngine module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 3 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPLv3 included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 3 requirements +** will be met: https://www.gnu.org/licenses/lgpl.html. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 2.0 or later as published by the Free +** Software Foundation and appearing in the file LICENSE.GPL included in +** the packaging of this file. Please review the following information to +** ensure the GNU General Public License version 2.0 requirements will be +** met: http://www.gnu.org/licenses/gpl-2.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#include "ssl_host_state_delegate_qt.h" + +#include "type_conversion.h" + +namespace QtWebEngineCore { + +// Mirrors implementation in aw_ssl_host_state_delegate.cc + +static net::SHA256HashValue getChainFingerprint256(const net::X509Certificate &cert) +{ + net::SHA256HashValue fingerprint = + net::X509Certificate::CalculateChainFingerprint256(cert.os_cert_handle(), cert.GetIntermediateCertificates()); + return fingerprint; +} + +CertPolicy::CertPolicy() +{ +} + +CertPolicy::~CertPolicy() +{ +} + +bool CertPolicy::Check(const net::X509Certificate& cert, net::CertStatus error) const +{ + net::SHA256HashValue fingerprint = getChainFingerprint256(cert); + auto allowed_iter = m_allowed.find(fingerprint); + if ((allowed_iter != m_allowed.end()) && (allowed_iter->second & error) && ((allowed_iter->second & error) == error)) + return true; + return false; +} + +void CertPolicy::Allow(const net::X509Certificate& cert, net::CertStatus error) +{ + net::SHA256HashValue fingerprint = getChainFingerprint256(cert); + m_allowed[fingerprint] |= error; +} + +SSLHostStateDelegateQt::SSLHostStateDelegateQt(BrowserContextAdapter *contextAdapter) + : m_contextAdapter(contextAdapter) +{ +} + +SSLHostStateDelegateQt::~SSLHostStateDelegateQt() +{ +} + +void SSLHostStateDelegateQt::AllowCert(const std::string &host, const net::X509Certificate &cert, net::CertStatus error) +{ + m_certPolicyforHost[host].Allow(cert, error); +} + +// Clear all allow preferences. +void SSLHostStateDelegateQt::Clear() +{ + m_certPolicyforHost.clear(); +} + +// Queries whether |cert| is allowed for |host| and |error|. Returns true in +// |expired_previous_decision| if a previous user decision expired immediately +// prior to this query, otherwise false. +content::SSLHostStateDelegate::CertJudgment SSLHostStateDelegateQt::QueryPolicy( + const std::string &host, const net::X509Certificate &cert, + net::CertStatus error,bool *expired_previous_decision) +{ + return m_certPolicyforHost[host].Check(cert, error) ? SSLHostStateDelegate::ALLOWED : SSLHostStateDelegate::DENIED; +} + +// Records that a host has run insecure content. +void SSLHostStateDelegateQt::HostRanInsecureContent(const std::string &host, int pid) +{ +} + +// Returns whether the specified host ran insecure content. +bool SSLHostStateDelegateQt::DidHostRunInsecureContent(const std::string &host, int pid) const +{ + return false; +} + +// Revokes all SSL certificate error allow exceptions made by the user for +// |host|. +void SSLHostStateDelegateQt::RevokeUserAllowExceptions(const std::string &host) +{ + m_certPolicyforHost.erase(host); +} + +// Returns whether the user has allowed a certificate error exception for +// |host|. This does not mean that *all* certificate errors are allowed, just +// that there exists an exception. To see if a particular certificate and +// error combination exception is allowed, use QueryPolicy(). +bool SSLHostStateDelegateQt::HasAllowException(const std::string &host) const +{ + auto policy_iterator = m_certPolicyforHost.find(host); + return policy_iterator != m_certPolicyforHost.end() && + policy_iterator->second.HasAllowException(); +} + + +} // namespace QtWebEngineCore diff --git a/src/core/ssl_host_state_delegate_qt.h b/src/core/ssl_host_state_delegate_qt.h new file mode 100644 index 000000000..7c91fcb2d --- /dev/null +++ b/src/core/ssl_host_state_delegate_qt.h @@ -0,0 +1,80 @@ +/**************************************************************************** +** +** Copyright (C) 2016 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtWebEngine module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 3 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPLv3 included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 3 requirements +** will be met: https://www.gnu.org/licenses/lgpl.html. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 2.0 or later as published by the Free +** Software Foundation and appearing in the file LICENSE.GPL included in +** the packaging of this file. Please review the following information to +** ensure the GNU General Public License version 2.0 requirements will be +** met: http://www.gnu.org/licenses/gpl-2.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef SSL_HOST_STATE_DELEGATE_QT_H +#define SSL_HOST_STATE_DELEGATE_QT_H + +#include "content/public/browser/ssl_host_state_delegate.h" +#include "browser_context_adapter.h" + +namespace QtWebEngineCore { + +class CertPolicy { +public: + CertPolicy(); + ~CertPolicy(); + bool Check(const net::X509Certificate& cert, net::CertStatus error) const; + void Allow(const net::X509Certificate& cert, net::CertStatus error); + bool HasAllowException() const { return m_allowed.size() > 0; } + +private: + std::map<net::SHA256HashValue, net::CertStatus, net::SHA256HashValueLessThan> m_allowed; +}; + +class SSLHostStateDelegateQt : public content::SSLHostStateDelegate { + +public: + SSLHostStateDelegateQt(BrowserContextAdapter *); + ~SSLHostStateDelegateQt(); + + // content::SSLHostStateDelegate implementation: + virtual void AllowCert(const std::string &, const net::X509Certificate &cert, net::CertStatus error) override; + virtual void Clear() override; + virtual CertJudgment QueryPolicy(const std::string &host, const net::X509Certificate &cert, + net::CertStatus error,bool *expired_previous_decision) override; + virtual void HostRanInsecureContent(const std::string &host, int pid) override; + virtual bool DidHostRunInsecureContent(const std::string &host, int pid) const override; + virtual void RevokeUserAllowExceptions(const std::string &host) override; + virtual bool HasAllowException(const std::string &host) const override; + +private: + BrowserContextAdapter *m_contextAdapter; + std::map<std::string, CertPolicy> m_certPolicyforHost; +}; + +} // namespace QtWebEngineCore + +#endif // SSL_HOST_STATE_DELEGATE_QT_H diff --git a/src/webengine/api/qquickwebengineprofile.cpp b/src/webengine/api/qquickwebengineprofile.cpp index 14405251e..0275d8a2a 100644 --- a/src/webengine/api/qquickwebengineprofile.cpp +++ b/src/webengine/api/qquickwebengineprofile.cpp @@ -62,17 +62,29 @@ ASSERT_ENUMS_MATCH(QQuickWebEngineDownloadItem::MimeHtmlSaveFormat, QtWebEngineC /*! \class QQuickWebEngineProfile - \brief The QQuickWebEngineProfile class provides a web-engine profile shared by multiple pages. + \brief The QQuickWebEngineProfile class provides a web engine profile shared by multiple pages. \since 5.6 \inmodule QtWebEngine - QQuickWebEngineProfile contains settings, scripts, and the list of visited links shared by all - web engine pages that belong to the profile. As such, profiles can be used to isolate pages - from each other. A typical use case is a dedicated profile for a 'private browsing' mode. + A web engine profile contains properties and functionality shared by a group of web engine + pages. + + Information about visited links is stored together with persistent cookies and other persistent + data in a storage described by the persistentStoragePath property. + + Profiles can be used to isolate pages from each other. A typical use case is a dedicated + \e {off-the-record profile} for a \e {private browsing} mode. An off-the-record profile forces + cookies, the HTTP cache, and other normally persistent data to be stored only in memory. The + offTheRecord property holds whether a profile is off-the-record. + + The default profile can be accessed by defaultProfile(). It is a built-in profile that all + web pages not specifically created with another profile belong to. - The default profile is a built-in profile that all web pages not specifically created with - another profile belong to. + A WebEngineProfile instance can be created and accessed from C++ through the + QQuickWebEngineProfile class, which exposes further functionality in C++. This allows Qt Quick + applications to intercept URL requests (QQuickWebEngineProfile::setRequestInterceptor), or + register custom URL schemes (QQuickWebEngineProfile::installUrlSchemeHandler). */ /*! diff --git a/src/webengine/api/qquickwebenginetestsupport.cpp b/src/webengine/api/qquickwebenginetestsupport.cpp index 33f48471a..46ffb06f4 100644 --- a/src/webengine/api/qquickwebenginetestsupport.cpp +++ b/src/webengine/api/qquickwebenginetestsupport.cpp @@ -51,6 +51,7 @@ void QQuickWebEngineErrorPage::loadFinished(bool success, const QUrl &url) { // Loading of the error page should not fail. Q_ASSERT(success); + Q_UNUSED(success); QQuickWebEngineLoadRequest loadRequest(url, QQuickWebEngineView::LoadSucceededStatus); Q_EMIT loadingChanged(&loadRequest); diff --git a/src/webengine/doc/src/qtwebengine-platform-notes.qdoc b/src/webengine/doc/src/qtwebengine-platform-notes.qdoc index 1f2d9dcf2..673215dd7 100644 --- a/src/webengine/doc/src/qtwebengine-platform-notes.qdoc +++ b/src/webengine/doc/src/qtwebengine-platform-notes.qdoc @@ -50,6 +50,9 @@ \li OS X: Xcode version 5.1 or later on OS X 10.9 or later \endlist + \note Qt WebEngine cannot be built for the 32-bit mode of OS X (using the + macx-clang-32 mkspec). + \section1 Pepper Plugin API Support Qt WebEngine supports loading Pepper Plugin API (PPAPI) plugins. The plugins must be loaded diff --git a/src/webenginewidgets/api/qwebengineprofile.cpp b/src/webenginewidgets/api/qwebengineprofile.cpp index 62836c5f9..50da38f22 100644 --- a/src/webenginewidgets/api/qwebengineprofile.cpp +++ b/src/webenginewidgets/api/qwebengineprofile.cpp @@ -63,17 +63,39 @@ using QtWebEngineCore::BrowserContextAdapter; /*! \class QWebEngineProfile - \brief The QWebEngineProfile class provides a web-engine profile shared by multiple pages. + \brief The QWebEngineProfile class provides a web engine profile shared by multiple pages. \since 5.5 \inmodule QtWebEngineWidgets - QWebEngineProfile contains settings, scripts, and the list of visited links shared by all - web engine pages that belong to the profile. As such, profiles can be used to isolate pages - from each other. A typical use case is a dedicated profile for a 'private browsing' mode. + A web engine profile contains settings, scripts, persistent cookie policy, and the list of + visited links shared by all web engine pages that belong to the profile. - The default profile is a built-in profile that all web pages not specifically created with - another profile belong to. + All pages that belong to the profile share a common QWebEngineSettings instance, which can + be accessed with the settings() method. Likewise, the scripts() method provides access + to a common QWebEngineScriptCollection instance. + + Information about visited links is stored together with persistent cookies and other persistent + data in a storage returned by persistentStoragePath(). The cache can be cleared of links by + clearVisitedLinks() or clearAllVisitedLinks(). PersistentCookiesPolicy describes whether + session and persistent cookies are saved to and restored from memory or disk. + + Profiles can be used to isolate pages from each other. A typical use case is a dedicated + \e {off-the-record profile} for a \e {private browsing} mode. Using QWebEngineProfile() without + defining a storage name constructs a new off-the-record profile that leaves no record on the + local machine, and has no persistent data or cache. The isOffTheRecord() method can be used + to check whether a profile is off-the-record. + + The default profile can be accessed by defaultProfile(). It is a built-in profile that all + web pages not specifically created with another profile belong to. + + Implementing the QWebEngineUrlRequestInterceptor interface and registering the interceptor on a + profile by setRequestInterceptor() enables intercepting, blocking, and modifying URL + requests (QWebEngineUrlRequestInfo) before they reach the networking stack of Chromium. + + A QWebEngineUrlSchemeHandler can be registered for a profile by installUrlSchemeHandler() + to add support for custom URL schemes. Requests for the scheme are then issued to + QWebEngineUrlSchemeHandler::requestStarted() as QWebEngineUrlRequestJob objects. */ /*! |