diff options
author | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2015-09-30 13:59:22 +0200 |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@theqtcompany.com> | 2015-10-06 07:56:49 +0000 |
commit | 442ad85ee3f40a981fa721673dd6c7344d1daece (patch) | |
tree | 324c86983c444ec3e38671afcb4619d6ad2261bd /src/core/custom_protocol_handler.h | |
parent | 295a915b5ae66ad9485b38e7d05040cf0321cd4e (diff) |
Remove unnecessay delegation over CustomUrlSchemeHandler
With QWebEngineSchemeHandler in QtWebEngineCore, we do not need the
indirection and delegation CustomUrlSchemeHandler provided. This
means the class can be removed and we can also store the handlers
directly in BrowserContextAdapter and save a copy of the installed
handlers in the QWebEngineProfile.
Change-Id: Iabb5cc9d364c2f2a879bc77bfb2ff14b3c2ff640
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Diffstat (limited to 'src/core/custom_protocol_handler.h')
-rw-r--r-- | src/core/custom_protocol_handler.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/custom_protocol_handler.h b/src/core/custom_protocol_handler.h index 225bb0567..94da28673 100644 --- a/src/core/custom_protocol_handler.h +++ b/src/core/custom_protocol_handler.h @@ -45,6 +45,7 @@ #include <QtCore/qcompilerdetection.h> // Needed for Q_DECL_OVERRIDE QT_FORWARD_DECLARE_CLASS(QIODevice) +QT_FORWARD_DECLARE_CLASS(QWebEngineUrlSchemeHandler) namespace net { class NetworkDelegate; @@ -54,20 +55,19 @@ class URLRequestJob; namespace QtWebEngineCore { class BrowserContextAdapter; -class CustomUrlSchemeHandler; // Implements a ProtocolHandler for custom URL schemes. // If |network_delegate_| is NULL then all file requests will fail with ERR_ACCESS_DENIED. class QWEBENGINE_EXPORT CustomProtocolHandler : public net::URLRequestJobFactory::ProtocolHandler { public: - CustomProtocolHandler(CustomUrlSchemeHandler *); + CustomProtocolHandler(QWebEngineUrlSchemeHandler *); virtual net::URLRequestJob *MaybeCreateJob(net::URLRequest *request, net::NetworkDelegate *networkDelegate) const Q_DECL_OVERRIDE; private: DISALLOW_COPY_AND_ASSIGN(CustomProtocolHandler); - CustomUrlSchemeHandler *m_schemeHandler; + QWebEngineUrlSchemeHandler *m_schemeHandler; }; } // namespace |