diff options
author | Peter Varga <pvarga@inf.u-szeged.hu> | 2021-02-05 10:56:48 +0100 |
---|---|---|
committer | Peter Varga <pvarga@inf.u-szeged.hu> | 2021-02-09 12:42:43 +0100 |
commit | 78c5516711414ed8fd9b1b473a58b038b4a80279 (patch) | |
tree | 66b54c20a3f0b467897f37d18bd2acaa6a8db909 /src/core/content_browser_client_qt.cpp | |
parent | 95e93830e45f5f10397248a794672ff6a681c8b8 (diff) |
Enable webrtc logging and the corresponding WebUI
The corresponding WebUI is chrome://webrtc-logs
It only makes sense with the hangout services extension. It seems to be
only useable with meet.google.com. The behavior is same for Chrome.
Uploading logs to Google is disabled in the Chromium patch. It is an
extension API functionality. The WebUI only lists the previously
generated logs.
Pulls in the following changes:
1dda5314b02 Enable webrtcLoggingPrivate extension API for hangout extension
7d71aca116d FIXUP: Enable webrtcLoggingPrivate extension API for hangout extension
Change-Id: I455fce7c8081e71967e55ab1f889df6ef91ed253
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/core/content_browser_client_qt.cpp')
-rw-r--r-- | src/core/content_browser_client_qt.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/core/content_browser_client_qt.cpp b/src/core/content_browser_client_qt.cpp index 5a30a4388..fbc57999e 100644 --- a/src/core/content_browser_client_qt.cpp +++ b/src/core/content_browser_client_qt.cpp @@ -111,6 +111,7 @@ #include "web_contents_adapter.h" #include "web_contents_delegate_qt.h" #include "web_contents_view_qt.h" +#include "web_engine_context.h" #include "web_engine_library_info.h" #include "api/qwebenginecookiestore.h" #include "api/qwebenginecookiestore_p.h" @@ -140,6 +141,10 @@ #include "components/spellcheck/common/spellcheck.mojom.h" #endif +#if QT_CONFIG(webengine_webrtc) && QT_CONFIG(webengine_extensions) +#include "chrome/browser/media/webrtc/webrtc_logging_controller.h" +#endif + #if defined(Q_OS_LINUX) #include "global_descriptors_qt.h" #endif @@ -319,6 +324,10 @@ void ContentBrowserClientQt::RenderProcessWillLaunch(content::RenderProcessHost const int id = host->GetID(); Profile *profile = Profile::FromBrowserContext(host->GetBrowserContext()); +#if QT_CONFIG(webengine_webrtc) && QT_CONFIG(webengine_extensions) + WebRtcLoggingController::AttachToRenderProcessHost(host, WebEngineContext::current()->webRtcLogUploader()); +#endif + // Allow requesting custom schemes. const auto policy = content::ChildProcessSecurityPolicy::GetInstance(); const auto profileAdapter = static_cast<ProfileQt *>(profile)->profileAdapter(); |