From 2a4a5b2ec17189d4ea8fa783cf219c65560e81f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCri=20Valdmann?= Date: Mon, 15 Jan 2018 17:57:05 +0100 Subject: Add support for registerProtocolHandler Extend initialization of URLRequestContextGetterQt to create a content::ProtocolHandlerRegistry for each content::BrowserContext and add the registry's URL request interceptor to the front of the interceptor chain. Implement methods in WebContentsDelegateQt to add/remove protocol handlers to/from the ProtocolHandlerRegistry. Add permission request signal and classes for core, quick and widgets. Add widgets autotest. Add signal handlers to quicknanobrowser and simplebrowser. Task-number: QTBUG-62783 Change-Id: I808e7eb9a1cb4d7216686deed4895de14fe46310 Reviewed-by: Allan Sandfeld Jensen --- src/webengine/doc/src/webengineview_lgpl.qdoc | 49 +++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) (limited to 'src/webengine/doc/src/webengineview_lgpl.qdoc') diff --git a/src/webengine/doc/src/webengineview_lgpl.qdoc b/src/webengine/doc/src/webengineview_lgpl.qdoc index c6985b082..104397bf7 100644 --- a/src/webengine/doc/src/webengineview_lgpl.qdoc +++ b/src/webengine/doc/src/webengineview_lgpl.qdoc @@ -1356,6 +1356,55 @@ Rejects a quota permission request. */ +/*! + \qmlsignal WebEngineView::registerProtocolHandlerPermissionRequested(RegisterProtocolHandlerPermissionRequest request) + \since QtWebEngine 1.7 + + This signal is emitted when the web page tries to register a custom protocol + using the \l registerProtocolHandler API. + + \sa RegisterProtocolHandlerPermissionRequest +*/ + +/*! + \qmltype RegisterProtocolHandlerPermissionRequest + \instantiates QQuickWebEngineRegisterProtocolHandlerPermissionRequest + \inqmlmodule QtWebEngine + \since QtWebEngine 1.7 + \brief The RegisterProtocolHandlerPermissionRequest type enables accepting + or rejecting requests from the \l registerProtocolHandler API. + + \sa WebEngineView::registerProtocolHandlerPermissionRequested() +*/ + +/*! + \qmlproperty url RegisterProtocolHandlerPermissionRequest::origin + \brief The URL template for the protocol handler. + + This is the second parameter from the \l registerProtocolHandler call. +*/ + +/*! + \qmlproperty string RegisterProtocolHandlerPermissionRequest::protocol + \brief The URL scheme for the protocol handler. + + This is the first parameter from the \l registerProtocolHandler call. +*/ + +/*! + \qmlmethod void RegisterProtocolHandlerPermissionRequest::accept() + \brief Accepts the request. + + Subsequent calls to accept() and reject() are ignored. +*/ + +/*! + \qmlmethod void RegisterProtocolHandlerPermissionRequest::reject() + \brief Accepts the request. + + Subsequent calls to accept() and reject() are ignored. +*/ + /*! \qmlsignal WebEngineView::geometryChangeRequested(rect geometry, rect frameGeometry) \since QtWebEngine 1.7 -- cgit v1.2.3