diff --git a/DEPS b/DEPS index 8dbacacddd3..a06c035096f 100644 --- a/DEPS +++ b/DEPS @@ -13,7 +13,7 @@ gclient_gn_args = [ vars = { 'chromium_version': - '9d15054f4cba060901e43deecf74002f11f47be3', + 'ff6c4f4b826d66c2e32380bf5d1eb5e1fe37faef', 'node_version': 'v12.16.3', 'nan_version': diff --git a/patches/chromium/.patches b/patches/chromium/.patches index 935fabe0f12..31a6d6f2505 100644 --- a/patches/chromium/.patches +++ b/patches/chromium/.patches @@ -95,6 +95,5 @@ upload_list_add_loadsync_method.patch breakpad_allow_getting_string_values_for_crash_keys.patch crash_allow_disabling_compression_on_linux.patch allow_setting_secondary_label_via_simplemenumodel.patch -fix_xserver_crash_when_using_xwindow_setxwindowicons.patch disable_unnecessary_ischromefirstrun_check.patch disable_dcheck_that_fails_with_software_compositing.patch diff --git a/patches/chromium/add_contentgpuclient_precreatemessageloop_callback.patch b/patches/chromium/add_contentgpuclient_precreatemessageloop_callback.patch index 213c279c45e..7c55b8fcf72 100644 --- a/patches/chromium/add_contentgpuclient_precreatemessageloop_callback.patch +++ b/patches/chromium/add_contentgpuclient_precreatemessageloop_callback.patch @@ -10,7 +10,7 @@ Allows Electron to restore WER when ELECTRON_DEFAULT_ERROR_MODE is set. This should be upstreamed. diff --git a/content/gpu/gpu_main.cc b/content/gpu/gpu_main.cc -index 4f34ae087e6e537869fe95858f943025ee32c82d..b1c939bd735ad6ed6a435258ef50c7a7ebf76481 100644 +index b502af8bb93dd45b5de046850f69ef34f9d04732..a6c84cd7909c6a1c70f3f4b5bd65531bf26f1a94 100644 --- a/content/gpu/gpu_main.cc +++ b/content/gpu/gpu_main.cc @@ -255,6 +255,10 @@ int GpuMain(const MainFunctionParams& parameters) { diff --git a/patches/chromium/add_didinstallconditionalfeatures.patch b/patches/chromium/add_didinstallconditionalfeatures.patch index a73b42482a8..773098d6223 100644 --- a/patches/chromium/add_didinstallconditionalfeatures.patch +++ b/patches/chromium/add_didinstallconditionalfeatures.patch @@ -23,10 +23,10 @@ index 831a3574055881f31a3e7dbc98c0525b47af5dcb..9626f181ee471fec68af7ddfc968f2d8 int32_t world_id) {} virtual void DidClearWindowObject() {} diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc -index c01f9074c4896d7d67609efa86d5a0e995fa974c..95cec369e38dada721cbf26fe244461171d748f8 100644 +index 0fe316e4d949bf2c0e64a2374a8f639e3afee104..cb612a7002a4ae808ca488e2aa2adbb759310964 100644 --- a/content/renderer/render_frame_impl.cc +++ b/content/renderer/render_frame_impl.cc -@@ -4807,6 +4807,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local context, +@@ -4729,6 +4729,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local context, observer.DidCreateScriptContext(context, world_id); } @@ -40,10 +40,10 @@ index c01f9074c4896d7d67609efa86d5a0e995fa974c..95cec369e38dada721cbf26fe2444611 int world_id) { for (auto& observer : observers_) diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h -index 2d34029a192ad9680d445ae6c5394f1fbfc7e894..9f21385919593cfb1314d9fb659e4b5a3326bf44 100644 +index c8772a65b238f52855a6634dbe1722491a663354..c856fb03735e3a46135492513e71daf3b1dc6c1a 100644 --- a/content/renderer/render_frame_impl.h +++ b/content/renderer/render_frame_impl.h -@@ -751,6 +751,8 @@ class CONTENT_EXPORT RenderFrameImpl +@@ -724,6 +724,8 @@ class CONTENT_EXPORT RenderFrameImpl bool ShouldTrackUseCounter(const blink::WebURL& url) override; void DidCreateScriptContext(v8::Local context, int world_id) override; @@ -53,10 +53,10 @@ index 2d34029a192ad9680d445ae6c5394f1fbfc7e894..9f21385919593cfb1314d9fb659e4b5a int world_id) override; void DidChangeScrollOffset() override; diff --git a/third_party/blink/public/web/web_local_frame_client.h b/third_party/blink/public/web/web_local_frame_client.h -index 5ab90fc0fb34c9bc5920b7d7efcb8819fed358c0..0a86dc4fc70e6c16e4cb27d6512ae5f589cd1125 100644 +index e8286b37ae00d2cbfea0f9138ecb6532c36324fc..1c5aae1c07e0c730a0cab28dccaa5a793d41d6ac 100644 --- a/third_party/blink/public/web/web_local_frame_client.h +++ b/third_party/blink/public/web/web_local_frame_client.h -@@ -548,6 +548,9 @@ class BLINK_EXPORT WebLocalFrameClient { +@@ -547,6 +547,9 @@ class BLINK_EXPORT WebLocalFrameClient { virtual void DidCreateScriptContext(v8::Local, int32_t world_id) {} @@ -79,7 +79,7 @@ index 1841d4bea144e2fe0fb69839d52ff2ba4aa6b551..64c5eb7d0da7684531b044de9d6d114f if (World().IsMainWorld()) { GetFrame()->Loader().DispatchDidClearWindowObjectInMainWorld(); diff --git a/third_party/blink/renderer/core/exported/local_frame_client_impl.cc b/third_party/blink/renderer/core/exported/local_frame_client_impl.cc -index 8639eecc68c75c311af8ae00c8e028b63624a986..e66039442fbd4d3a456a724afe5eb28314459dc5 100644 +index eae1fafbaab524e590f414b54b366a6d709fad47..97da1b1639618dded697eb72d5959926ce725e24 100644 --- a/third_party/blink/renderer/core/exported/local_frame_client_impl.cc +++ b/third_party/blink/renderer/core/exported/local_frame_client_impl.cc @@ -348,6 +348,13 @@ void LocalFrameClientImpl::DidCreateScriptContext( @@ -97,7 +97,7 @@ index 8639eecc68c75c311af8ae00c8e028b63624a986..e66039442fbd4d3a456a724afe5eb283 v8::Local context, int32_t world_id) { diff --git a/third_party/blink/renderer/core/exported/local_frame_client_impl.h b/third_party/blink/renderer/core/exported/local_frame_client_impl.h -index 2dd3d3d0d036cce2ad49be52915e00c6872eca43..b7c0f955a3388f2c7758d2058d3077e2ba4e8496 100644 +index 7494f29aebe486454f35209a4a72d42dd46431a0..89f4129124b7fb01c449c51f767f4fe0dcc9c299 100644 --- a/third_party/blink/renderer/core/exported/local_frame_client_impl.h +++ b/third_party/blink/renderer/core/exported/local_frame_client_impl.h @@ -78,6 +78,8 @@ class LocalFrameClientImpl final : public LocalFrameClient { @@ -110,7 +110,7 @@ index 2dd3d3d0d036cce2ad49be52915e00c6872eca43..b7c0f955a3388f2c7758d2058d3077e2 int32_t world_id) override; diff --git a/third_party/blink/renderer/core/frame/local_frame_client.h b/third_party/blink/renderer/core/frame/local_frame_client.h -index b9a8d9bce7a02a6f46b91697efd4a32d62638f57..99d6bbdf43748adabf2084310abe458383a25f77 100644 +index a8443a8bfc2542ffad472206214279c1223d493f..8c7a4dec19d6fbca615b7bc282b0388189eef886 100644 --- a/third_party/blink/renderer/core/frame/local_frame_client.h +++ b/third_party/blink/renderer/core/frame/local_frame_client.h @@ -297,6 +297,8 @@ class CORE_EXPORT LocalFrameClient : public FrameClient { diff --git a/patches/chromium/add_trustedauthclient_to_urlloaderfactory.patch b/patches/chromium/add_trustedauthclient_to_urlloaderfactory.patch index 3b5f05b74fd..47ab4361154 100644 --- a/patches/chromium/add_trustedauthclient_to_urlloaderfactory.patch +++ b/patches/chromium/add_trustedauthclient_to_urlloaderfactory.patch @@ -10,7 +10,7 @@ WebContents, and cancels the authentication if there's no WebContents available, which there isn't in the case of the 'net' module. diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom -index 6ec25efe5bb2819df27d0ba8fc0646f2b80668a8..06ec91de21cb51e0fba363fd54e7bb3a56b8e391 100644 +index 2001e6202cf61d1c70bf81334b62d0502ea8c9ba..9dad884c877ae77d1a2460361112903c06023021 100644 --- a/services/network/public/mojom/network_context.mojom +++ b/services/network/public/mojom/network_context.mojom @@ -198,6 +198,25 @@ struct CTPolicy { @@ -39,7 +39,7 @@ index 6ec25efe5bb2819df27d0ba8fc0646f2b80668a8..06ec91de21cb51e0fba363fd54e7bb3a interface CertVerifierClient { Verify( int32 default_error, -@@ -645,6 +664,8 @@ struct URLLoaderFactoryParams { +@@ -627,6 +646,8 @@ struct URLLoaderFactoryParams { // impact because of the extra process hops, so use should be minimized. pending_remote? header_client; @@ -49,10 +49,10 @@ index 6ec25efe5bb2819df27d0ba8fc0646f2b80668a8..06ec91de21cb51e0fba363fd54e7bb3a // the per-context allow patterns that is managed via NetworkContext // interface. This still respects the per-context block lists. diff --git a/services/network/url_loader.cc b/services/network/url_loader.cc -index 39c382067febf8c317ceca3569555b12cb060f18..8ea8397c55882827f6ff3e9807dc13c6df5301d3 100644 +index 5d984482a2e5e18216bfc2229a18a513558dbcf4..1662f0878df16639ad585694be428058ab5a6c92 100644 --- a/services/network/url_loader.cc +++ b/services/network/url_loader.cc -@@ -436,6 +436,7 @@ URLLoader::URLLoader( +@@ -437,6 +437,7 @@ URLLoader::URLLoader( base::WeakPtr keepalive_statistics_recorder, base::WeakPtr network_usage_accumulator, mojom::TrustedURLLoaderHeaderClient* url_loader_header_client, @@ -60,7 +60,7 @@ index 39c382067febf8c317ceca3569555b12cb060f18..8ea8397c55882827f6ff3e9807dc13c6 mojom::OriginPolicyManager* origin_policy_manager, std::unique_ptr trust_token_helper_factory, mojo::PendingRemote cookie_observer) -@@ -495,6 +496,11 @@ URLLoader::URLLoader( +@@ -496,6 +497,11 @@ URLLoader::URLLoader( header_client_.set_disconnect_handler( base::BindOnce(&URLLoader::OnMojoDisconnect, base::Unretained(this))); } @@ -72,7 +72,7 @@ index 39c382067febf8c317ceca3569555b12cb060f18..8ea8397c55882827f6ff3e9807dc13c6 if (want_raw_headers_) { options_ |= mojom::kURLLoadOptionSendSSLInfoWithResponse | mojom::kURLLoadOptionSendSSLInfoForCertificateError; -@@ -990,7 +996,7 @@ void URLLoader::OnReceivedRedirect(net::URLRequest* url_request, +@@ -994,7 +1000,7 @@ void URLLoader::OnReceivedRedirect(net::URLRequest* url_request, void URLLoader::OnAuthRequired(net::URLRequest* url_request, const net::AuthChallengeInfo& auth_info) { @@ -81,7 +81,7 @@ index 39c382067febf8c317ceca3569555b12cb060f18..8ea8397c55882827f6ff3e9807dc13c6 OnAuthCredentials(base::nullopt); return; } -@@ -1006,11 +1012,20 @@ void URLLoader::OnAuthRequired(net::URLRequest* url_request, +@@ -1010,11 +1016,20 @@ void URLLoader::OnAuthRequired(net::URLRequest* url_request, if (url_request->response_headers()) head->headers = url_request->response_headers(); head->auth_challenge_info = auth_info; @@ -108,7 +108,7 @@ index 39c382067febf8c317ceca3569555b12cb060f18..8ea8397c55882827f6ff3e9807dc13c6 auth_challenge_responder_receiver_.set_disconnect_handler( base::BindOnce(&URLLoader::DeleteSelf, base::Unretained(this))); diff --git a/services/network/url_loader.h b/services/network/url_loader.h -index c8c09642661ca9a3c42e2c928bfd221b40830744..b202db0ccf6d40c534aa8d320291e8a85653a2ce 100644 +index 077344d12f001b00590598bccbba2d614c8c1af2..d9c8a41c9c4fe11277392dd428c71f022f22063b 100644 --- a/services/network/url_loader.h +++ b/services/network/url_loader.h @@ -115,6 +115,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader @@ -119,7 +119,7 @@ index c8c09642661ca9a3c42e2c928bfd221b40830744..b202db0ccf6d40c534aa8d320291e8a8 mojom::OriginPolicyManager* origin_policy_manager, std::unique_ptr trust_token_helper_factory, -@@ -453,6 +454,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader +@@ -454,6 +455,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader base::Optional fetch_window_id_; mojo::Remote header_client_; diff --git a/patches/chromium/blink_local_frame.patch b/patches/chromium/blink_local_frame.patch index e83a5e14e75..86323d2dda1 100644 --- a/patches/chromium/blink_local_frame.patch +++ b/patches/chromium/blink_local_frame.patch @@ -14,10 +14,10 @@ when there is code doing that. This patch reverts the change to fix the crash in Electron. diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc -index edaeb74fd7c8cd93fd72dd547bf028415ca891f4..d7be295d1113bf2376c8353fa767578d49cd8cde 100644 +index c04ca5b367d6a5b0de3adb9e63d2b79ecee1c83d..10d113e0d15a6379d31f2d44df7bc42b339e963e 100644 --- a/third_party/blink/renderer/core/frame/local_frame.cc +++ b/third_party/blink/renderer/core/frame/local_frame.cc -@@ -528,10 +528,6 @@ void LocalFrame::DetachImpl(FrameDetachType type) { +@@ -533,10 +533,6 @@ void LocalFrame::DetachImpl(FrameDetachType type) { } CHECK(!view_ || !view_->IsAttached()); @@ -28,7 +28,7 @@ index edaeb74fd7c8cd93fd72dd547bf028415ca891f4..d7be295d1113bf2376c8353fa767578d if (!Client()) return; -@@ -549,6 +545,10 @@ void LocalFrame::DetachImpl(FrameDetachType type) { +@@ -554,6 +550,10 @@ void LocalFrame::DetachImpl(FrameDetachType type) { // Notify ScriptController that the frame is closing, since its cleanup ends // up calling back to LocalFrameClient via WindowProxy. GetScriptController().ClearForClose(); diff --git a/patches/chromium/blink_world_context.patch b/patches/chromium/blink_world_context.patch index 578d7cdf816..5ea0221c1e2 100644 --- a/patches/chromium/blink_world_context.patch +++ b/patches/chromium/blink_world_context.patch @@ -7,24 +7,23 @@ This exposes a method for obtaining a reference to an isolated world, which is otherwise not available in the Blink API. diff --git a/third_party/blink/public/web/web_local_frame.h b/third_party/blink/public/web/web_local_frame.h -index 63d2e8e3489d58f8163ae551ebda6bc718367c5c..628bb9667a6fc4830dfbb6711f59b83bff364bec 100644 +index 282839542f03317b919a300aa5b00efbc1045ede..3b22d8712a0437a760d6b0d822f97b01a3a08d22 100644 --- a/third_party/blink/public/web/web_local_frame.h +++ b/third_party/blink/public/web/web_local_frame.h -@@ -337,6 +337,9 @@ class WebLocalFrame : public WebFrame { - // be calling this API. - virtual v8::Local MainWorldScriptContext() const = 0; - +@@ -341,6 +341,8 @@ class WebLocalFrame : public WebFrame { + // Returns the world ID associated with |script_context|. + virtual int32_t GetScriptContextWorldId( + v8::Local script_context) const = 0; + virtual v8::Local WorldScriptContext( + v8::Isolate* isolate, int world_id) const = 0; -+ + // Executes script in the context of the current page and returns the value // that the script evaluated to with callback. Script execution can be - // suspend. diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc -index 8ec99c1f8a5f3327b04ac1682861adc0c325a554..da8858ade5c52301393db79a4b19796aded032f3 100644 +index 73aa50d81c4acf066e31b44614f7bdb375e9a159..37bc11b20b4b0944ac75dc96109980c8cfc13b0b 100644 --- a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc +++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc -@@ -945,6 +945,13 @@ v8::Local WebLocalFrameImpl::GlobalProxy() const { +@@ -952,6 +952,13 @@ v8::Local WebLocalFrameImpl::GlobalProxy() const { return MainWorldScriptContext()->Global(); } @@ -39,13 +38,13 @@ index 8ec99c1f8a5f3327b04ac1682861adc0c325a554..da8858ade5c52301393db79a4b19796a return BindingSecurity::ShouldAllowAccessToFrame( CurrentDOMWindow(V8PerIsolateData::MainThreadIsolate()), diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.h b/third_party/blink/renderer/core/frame/web_local_frame_impl.h -index 9997c78cd84282c4bf4ddb3235b2195f4eda1cb4..1e52665009df85961c5685fc62bced18c06ce927 100644 +index 44f6172f65c45e46bd686d2135d09e3dc6844976..5f6a6bc7aad3acb5eb2640aabf029001fbeea267 100644 --- a/third_party/blink/renderer/core/frame/web_local_frame_impl.h +++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.h -@@ -159,6 +159,8 @@ class CORE_EXPORT WebLocalFrameImpl final - int argc, - v8::Local argv[]) override; +@@ -161,6 +161,8 @@ class CORE_EXPORT WebLocalFrameImpl final v8::Local MainWorldScriptContext() const override; + int32_t GetScriptContextWorldId( + v8::Local script_context) const override; + v8::Local WorldScriptContext( + v8::Isolate* isolate, int world_id) const override; void RequestExecuteScriptAndReturnValue(const WebScriptSource&, diff --git a/patches/chromium/build_add_electron_tracing_category.patch b/patches/chromium/build_add_electron_tracing_category.patch index fb3b2052295..582255cc43d 100644 --- a/patches/chromium/build_add_electron_tracing_category.patch +++ b/patches/chromium/build_add_electron_tracing_category.patch @@ -8,7 +8,7 @@ categories in use are known / declared. This patch is required for us to introduce a new Electron category for Electron-specific tracing. diff --git a/base/trace_event/builtin_categories.h b/base/trace_event/builtin_categories.h -index d02299e1fa84ee99930a4079e1494672be1d8a60..4b3ceec51304913f3ee9172a2c533f159ed81bd5 100644 +index 8f6f08406e743cfabd653c7f9e4bf32802e0cf65..5dfd3cc573d6c56c53f608c4258d7f0abc9f639a 100644 --- a/base/trace_event/builtin_categories.h +++ b/base/trace_event/builtin_categories.h @@ -73,6 +73,7 @@ diff --git a/patches/chromium/build_gn.patch b/patches/chromium/build_gn.patch index 84bd62388ab..645d0ff8ce6 100644 --- a/patches/chromium/build_gn.patch +++ b/patches/chromium/build_gn.patch @@ -14,7 +14,7 @@ tradeoff is that switching from MAS_BUILD to !MAS_BUILD or vice-versa will rebuild the entire tree. diff --git a/build/config/BUILDCONFIG.gn b/build/config/BUILDCONFIG.gn -index 6f5d5f123f89c5ef4dd601eddb6025bd4dc3b9ab..b39aa4b3181489e5ea270c6cd3f30adfbb9847a0 100644 +index 33416d571f2d2a672daf62be21bfb97dfc998b51..a1f21871c1806857723d3a421e5ef3917d7f1ef0 100644 --- a/build/config/BUILDCONFIG.gn +++ b/build/config/BUILDCONFIG.gn @@ -123,6 +123,9 @@ if (current_os == "") { diff --git a/patches/chromium/can_create_window.patch b/patches/chromium/can_create_window.patch index 6506a08af59..3c2b1c6b207 100644 --- a/patches/chromium/can_create_window.patch +++ b/patches/chromium/can_create_window.patch @@ -9,10 +9,10 @@ potentially prevent a window from being created. TODO(loc): this patch is currently broken. diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc -index fd47808a5a1e51dcca00ac7daff7107e3dfa17e4..f30eeb4f36c86431df1c965273eb188490db4ac0 100644 +index 21ff33131e62938ab04399a70d392ccbe5282034..79abda0cc919e3a79b49ebd417bf86368934bbd1 100644 --- a/content/browser/frame_host/render_frame_host_impl.cc +++ b/content/browser/frame_host/render_frame_host_impl.cc -@@ -4654,6 +4654,7 @@ void RenderFrameHostImpl::CreateNewWindow( +@@ -4691,6 +4691,7 @@ void RenderFrameHostImpl::CreateNewWindow( last_committed_origin_, params->window_container_type, params->target_url, params->referrer.To(), params->frame_name, params->disposition, *params->features, @@ -21,10 +21,10 @@ index fd47808a5a1e51dcca00ac7daff7107e3dfa17e4..f30eeb4f36c86431df1c965273eb1884 &no_javascript_access); diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc -index a9c62d7efd00fea602cced369f64fb81c068b8cc..c017455770707877008e2df07e65c391068bdb8c 100644 +index d2b8edd094a8585fe14e144e881feafd0917199a..e282718ec461f6c7bcb1fe36d5bb73359f04a30a 100644 --- a/content/browser/web_contents/web_contents_impl.cc +++ b/content/browser/web_contents/web_contents_impl.cc -@@ -2955,9 +2955,9 @@ RenderFrameHostDelegate* WebContentsImpl::CreateNewWindow( +@@ -2969,9 +2969,9 @@ RenderFrameHostDelegate* WebContentsImpl::CreateNewWindow( } if (delegate_) { @@ -38,10 +38,10 @@ index a9c62d7efd00fea602cced369f64fb81c068b8cc..c017455770707877008e2df07e65c391 for (auto& observer : observers_) { diff --git a/content/common/frame.mojom b/content/common/frame.mojom -index b6113c360f9e033440c3043a128531704778fe9c..9732b9ad4562b503041e19f2763d697e6c191e1c 100644 +index 21811c17c9ffc37ccae543a7f5d2181987e144ab..697acddd922caa5f5df27219b0e109a1c72b6b2b 100644 --- a/content/common/frame.mojom +++ b/content/common/frame.mojom -@@ -302,6 +302,10 @@ struct CreateNewWindowParams { +@@ -256,6 +256,10 @@ struct CreateNewWindowParams { // The window features to use for the new window. blink.mojom.WindowFeatures features; @@ -53,10 +53,10 @@ index b6113c360f9e033440c3043a128531704778fe9c..9732b9ad4562b503041e19f2763d697e // Operation result when the renderer asks the browser to create a new window. diff --git a/content/public/browser/content_browser_client.cc b/content/public/browser/content_browser_client.cc -index ba197ce381396608ab8603d27752b1bfe30e8e84..3c743a74321d54e36248d7b6201d9fdf5b749af6 100644 +index 8cfe2bfebd69be8aa4ed4fd1a8b846e7237be68f..8f36f7277a59d297a0700d1dfd5d8120f6a0ffa1 100644 --- a/content/public/browser/content_browser_client.cc +++ b/content/public/browser/content_browser_client.cc -@@ -524,6 +524,8 @@ bool ContentBrowserClient::CanCreateWindow( +@@ -530,6 +530,8 @@ bool ContentBrowserClient::CanCreateWindow( const std::string& frame_name, WindowOpenDisposition disposition, const blink::mojom::WindowFeatures& features, @@ -66,7 +66,7 @@ index ba197ce381396608ab8603d27752b1bfe30e8e84..3c743a74321d54e36248d7b6201d9fdf bool opener_suppressed, bool* no_javascript_access) { diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h -index d6c203ab546dde5106383c4d357d52c88965c467..491d6e7260dd329f312916c2f4aaba0aa177cc6a 100644 +index 21c7cfe08903cf92948af5fe069d7b25035c23fe..463fcc56d05a2e18c1d3752b5e7e275c8797eca8 100644 --- a/content/public/browser/content_browser_client.h +++ b/content/public/browser/content_browser_client.h @@ -146,6 +146,7 @@ class NetworkService; @@ -77,7 +77,7 @@ index d6c203ab546dde5106383c4d357d52c88965c467..491d6e7260dd329f312916c2f4aaba0a } // namespace network namespace rappor { -@@ -845,6 +846,8 @@ class CONTENT_EXPORT ContentBrowserClient { +@@ -851,6 +852,8 @@ class CONTENT_EXPORT ContentBrowserClient { const std::string& frame_name, WindowOpenDisposition disposition, const blink::mojom::WindowFeatures& features, @@ -109,7 +109,7 @@ index 6017278cc0fa8d029477e7ef46a9c0cacae438be..18161c8f836134e470333381a16425e3 const OpenURLParams& params) { return nullptr; diff --git a/content/public/browser/web_contents_delegate.h b/content/public/browser/web_contents_delegate.h -index 7757c7720406aa9915a2a413b939be968c3cd988..7b329848850638941a7d8564dfe3786ae6f489ff 100644 +index 3844c78d8e56c43e08786af3128a1bcda3fc5839..089291f17512d24697ace85c93d1b3d4e024edf2 100644 --- a/content/public/browser/web_contents_delegate.h +++ b/content/public/browser/web_contents_delegate.h @@ -16,6 +16,7 @@ @@ -135,7 +135,7 @@ index 7757c7720406aa9915a2a413b939be968c3cd988..7b329848850638941a7d8564dfe3786a // typically happens when popups are created. virtual void WebContentsCreated(WebContents* source_contents, diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc -index 20ec8fc88cba99266ca9cf5f22f2565a762a97b3..00333d9aa46d643bf65db07cfac7a3a8959a14a3 100644 +index 0d7c504ce1fb7cbd72e7b176f6d88d1734034cc0..80278388015825fee05771aff7af3376d327058a 100644 --- a/content/renderer/render_view_impl.cc +++ b/content/renderer/render_view_impl.cc @@ -68,6 +68,7 @@ @@ -146,7 +146,7 @@ index 20ec8fc88cba99266ca9cf5f22f2565a762a97b3..00333d9aa46d643bf65db07cfac7a3a8 #include "content/renderer/media/audio/audio_device_factory.h" #include "content/renderer/render_frame_impl.h" #include "content/renderer/render_frame_proxy.h" -@@ -1250,6 +1251,10 @@ WebView* RenderViewImpl::CreateView( +@@ -1245,6 +1246,10 @@ WebView* RenderViewImpl::CreateView( } params->features = ConvertWebWindowFeaturesToMojoWindowFeatures(features); @@ -158,10 +158,10 @@ index 20ec8fc88cba99266ca9cf5f22f2565a762a97b3..00333d9aa46d643bf65db07cfac7a3a8 // moved on send. bool is_background_tab = diff --git a/content/shell/browser/web_test/web_test_content_browser_client.cc b/content/shell/browser/web_test/web_test_content_browser_client.cc -index f963cc714c49c90b66195e84b4fdda9b1f38ad28..c6e10685403a1f6dd3f326b001d9ee5e2e351e67 100644 +index c69a7f463fbf629320c88f65a9c0f6ce9c3bf0db..6d7f47624414c4e9e77680e415facd8f3e2130ee 100644 --- a/content/shell/browser/web_test/web_test_content_browser_client.cc +++ b/content/shell/browser/web_test/web_test_content_browser_client.cc -@@ -401,6 +401,8 @@ bool WebTestContentBrowserClient::CanCreateWindow( +@@ -400,6 +400,8 @@ bool WebTestContentBrowserClient::CanCreateWindow( const std::string& frame_name, WindowOpenDisposition disposition, const blink::mojom::WindowFeatures& features, @@ -206,10 +206,10 @@ index 4f735ad0d97eaac9a57dad137e479f8a7ec33a36..0a3c5821962c85609b64b3625fa6b8d6 } // namespace blink diff --git a/third_party/blink/renderer/core/frame/local_dom_window.cc b/third_party/blink/renderer/core/frame/local_dom_window.cc -index 1d5c3315671f0c414572ee0610fe6ac399b6e1e8..ee2c97cd344ea5f6e3aadd34304d290dbf5d2587 100644 +index 5137d99c8e94b8f2dfb903b3de87d2dfcfd14380..5859fa66f7878b77ccea0c41f22845f617123684 100644 --- a/third_party/blink/renderer/core/frame/local_dom_window.cc +++ b/third_party/blink/renderer/core/frame/local_dom_window.cc -@@ -1874,6 +1874,7 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate, +@@ -1837,6 +1837,7 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate, } WebWindowFeatures window_features = GetWindowFeaturesFromString(features); diff --git a/patches/chromium/chore_use_electron_resources_not_chrome_for_spellchecker.patch b/patches/chromium/chore_use_electron_resources_not_chrome_for_spellchecker.patch index fa8f3609abf..c0416ef10b6 100644 --- a/patches/chromium/chore_use_electron_resources_not_chrome_for_spellchecker.patch +++ b/patches/chromium/chore_use_electron_resources_not_chrome_for_spellchecker.patch @@ -7,10 +7,10 @@ spellchecker uses a few IDS_ resources. We need to load these from Electrons grit header instead of Chromes diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn -index c404e7a7171288e9f169fe2c80a35c53b7f27949..f846309e2139507cba9ba927d4eb401e4b2e2ec1 100644 +index c2b29ac310b445a9544bc7d81d3e54003f327c90..8740a49e0c3cf822da7cda504052ee7b93826bb8 100644 --- a/chrome/browser/BUILD.gn +++ b/chrome/browser/BUILD.gn -@@ -5388,6 +5388,7 @@ static_library("browser") { +@@ -5403,6 +5403,7 @@ static_library("browser") { deps += [ "//components/spellcheck/browser", "//components/spellcheck/common", diff --git a/patches/chromium/content_browser_main_loop.patch b/patches/chromium/content_browser_main_loop.patch index 9f13928f486..b9b48046af6 100644 --- a/patches/chromium/content_browser_main_loop.patch +++ b/patches/chromium/content_browser_main_loop.patch @@ -8,10 +8,10 @@ run before shutdown. This is required to cleanup WebContents asynchronously in atom::CommonWebContentsDelegate::ResetManageWebContents. diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc -index d014ef7e1d8d10d049efb4687dac55191355a5d8..51b0ed369be74cec504abf6e933917fdf7a62aad 100644 +index d01f1fcfd6259c82b0fab35345b05b771c6a933b..554170ffdb2f9f852ade0be8173a2c306840401d 100644 --- a/content/browser/browser_main_loop.cc +++ b/content/browser/browser_main_loop.cc -@@ -1488,7 +1488,7 @@ void BrowserMainLoop::MainMessageLoopRun() { +@@ -1482,7 +1482,7 @@ void BrowserMainLoop::MainMessageLoopRun() { NOTREACHED(); #else base::RunLoop run_loop; diff --git a/patches/chromium/dcheck.patch b/patches/chromium/dcheck.patch index cdcd95493f9..71c6bd451fe 100644 --- a/patches/chromium/dcheck.patch +++ b/patches/chromium/dcheck.patch @@ -17,10 +17,10 @@ only one or two specific checks fail. Then it's better to simply comment out the failing checks and allow the rest of the target to have them enabled. diff --git a/content/browser/frame_host/navigation_controller_impl.cc b/content/browser/frame_host/navigation_controller_impl.cc -index ddb106d49ab6c175ada8bbc20bee1a00df236c73..aea2b686251738d686f249cd760ca40822b70cb4 100644 +index 86a9e8c358ca6c70b07e17cf8dbcdb013472a3be..633f93d28840c350e8cda3dde96b98ac019bc9e7 100644 --- a/content/browser/frame_host/navigation_controller_impl.cc +++ b/content/browser/frame_host/navigation_controller_impl.cc -@@ -1289,8 +1289,10 @@ NavigationType NavigationControllerImpl::ClassifyNavigation( +@@ -1253,8 +1253,10 @@ NavigationType NavigationControllerImpl::ClassifyNavigation( return NAVIGATION_TYPE_NEW_SUBFRAME; } @@ -33,7 +33,7 @@ index ddb106d49ab6c175ada8bbc20bee1a00df236c73..aea2b686251738d686f249cd760ca408 if (rfh->GetParent()) { // All manual subframes would be did_create_new_entry and handled above, so -@@ -1545,7 +1547,10 @@ void NavigationControllerImpl::RendererDidNavigateToNewPage( +@@ -1510,7 +1512,10 @@ void NavigationControllerImpl::RendererDidNavigateToNewPage( new_entry->GetFavicon() = GetLastCommittedEntry()->GetFavicon(); } diff --git a/patches/chromium/delay_lock_the_protocol_scheme_registry.patch b/patches/chromium/delay_lock_the_protocol_scheme_registry.patch index 2b379107b0b..8e6c50756b7 100644 --- a/patches/chromium/delay_lock_the_protocol_scheme_registry.patch +++ b/patches/chromium/delay_lock_the_protocol_scheme_registry.patch @@ -19,10 +19,10 @@ https://chromium-review.googlesource.com/c/chromium/src/+/1901591, we should try re-submitting the patch. diff --git a/content/app/content_main_runner_impl.cc b/content/app/content_main_runner_impl.cc -index 474f742a909b0a425c6b1f3e93da211b4bcee919..16b9f816d56dbb6b6943cca6d6b3610afa322f4e 100644 +index 0d752de291c071e9a6054d7ced3ac1930fa38471..05e1e711e1a4abc1aab79fdbb4cda63cbf282e94 100644 --- a/content/app/content_main_runner_impl.cc +++ b/content/app/content_main_runner_impl.cc -@@ -634,7 +634,7 @@ int ContentMainRunnerImpl::Initialize(const ContentMainParams& params) { +@@ -656,7 +656,7 @@ int ContentMainRunnerImpl::Initialize(const ContentMainParams& params) { } #endif diff --git a/patches/chromium/desktop_media_list.patch b/patches/chromium/desktop_media_list.patch index 4789095565f..cb55a463729 100644 --- a/patches/chromium/desktop_media_list.patch +++ b/patches/chromium/desktop_media_list.patch @@ -29,10 +29,10 @@ index a489bf6ea2179059f53e53563e993db9c7cd123b..93e237569fe94ec8526f67d915e1a735 virtual content::DesktopMediaID::Type GetMediaListType() const = 0; }; diff --git a/chrome/browser/media/webrtc/desktop_media_list_base.cc b/chrome/browser/media/webrtc/desktop_media_list_base.cc -index ba64a40697c7bb91d6e944ad9ea8fa50dd970633..d2600791197082c8c2e179ee4df66965234c4542 100644 +index 147d5be9f7f56fb71468b56e86eb33b59d51cd66..5930fe95e33a9e5a3108c31e8c34daa9c724511c 100644 --- a/chrome/browser/media/webrtc/desktop_media_list_base.cc +++ b/chrome/browser/media/webrtc/desktop_media_list_base.cc -@@ -22,6 +22,11 @@ DesktopMediaListBase::DesktopMediaListBase(base::TimeDelta update_period) +@@ -20,6 +20,11 @@ DesktopMediaListBase::DesktopMediaListBase(base::TimeDelta update_period) DesktopMediaListBase::~DesktopMediaListBase() {} @@ -44,7 +44,7 @@ index ba64a40697c7bb91d6e944ad9ea8fa50dd970633..d2600791197082c8c2e179ee4df66965 void DesktopMediaListBase::SetUpdatePeriod(base::TimeDelta period) { DCHECK(!observer_); update_period_ = period; -@@ -56,7 +61,7 @@ void DesktopMediaListBase::Update(UpdateCallback callback) { +@@ -54,7 +59,7 @@ void DesktopMediaListBase::Update(UpdateCallback callback) { DCHECK(sources_.empty()); DCHECK(!refresh_callback_); refresh_callback_ = std::move(callback); @@ -53,7 +53,7 @@ index ba64a40697c7bb91d6e944ad9ea8fa50dd970633..d2600791197082c8c2e179ee4df66965 } int DesktopMediaListBase::GetSourceCount() const { -@@ -70,6 +75,11 @@ const DesktopMediaList::Source& DesktopMediaListBase::GetSource( +@@ -68,6 +73,11 @@ const DesktopMediaList::Source& DesktopMediaListBase::GetSource( return sources_[index]; } @@ -65,7 +65,7 @@ index ba64a40697c7bb91d6e944ad9ea8fa50dd970633..d2600791197082c8c2e179ee4df66965 DesktopMediaID::Type DesktopMediaListBase::GetMediaListType() const { return type_; } -@@ -81,6 +91,12 @@ DesktopMediaListBase::SourceDescription::SourceDescription( +@@ -79,6 +89,12 @@ DesktopMediaListBase::SourceDescription::SourceDescription( void DesktopMediaListBase::UpdateSourcesList( const std::vector& new_sources) { @@ -111,16 +111,15 @@ index ad7f766a36b1b6b2a8bc0f96369f1aaadf6681f7..f6c6c14a0937430df62c9b9c1132c591 protected: virtual ~DesktopMediaListObserver() {} diff --git a/chrome/browser/media/webrtc/native_desktop_media_list.cc b/chrome/browser/media/webrtc/native_desktop_media_list.cc -index c81645e60a2a31429051fdfbf29666a09fa19c61..b3a6ed705f2f8bbbe74ec7e84ab07dc64f231dfd 100644 +index 622d9a22c8e53ba13f00c078a8240c0449c0900a..a190f487c7c388631e83bb951420d699b913bdea 100644 --- a/chrome/browser/media/webrtc/native_desktop_media_list.cc +++ b/chrome/browser/media/webrtc/native_desktop_media_list.cc -@@ -10,14 +10,15 @@ +@@ -10,13 +10,14 @@ #include "base/hash/hash.h" #include "base/message_loop/message_pump_type.h" #include "base/single_thread_task_runner.h" +#include "base/strings/string_number_conversions.h" #include "base/strings/utf_string_conversions.h" - #include "base/task/post_task.h" #include "base/threading/thread_restrictions.h" #include "build/build_config.h" #include "chrome/browser/media/webrtc/desktop_media_list.h" @@ -131,8 +130,8 @@ index c81645e60a2a31429051fdfbf29666a09fa19c61..b3a6ed705f2f8bbbe74ec7e84ab07dc6 #include "media/base/video_util.h" #include "third_party/libyuv/include/libyuv/scale_argb.h" #include "third_party/skia/include/core/SkBitmap.h" -@@ -223,6 +224,8 @@ void NativeDesktopMediaList::Worker::RefreshThumbnails( - FROM_HERE, {BrowserThread::UI}, +@@ -221,6 +222,8 @@ void NativeDesktopMediaList::Worker::RefreshThumbnails( + FROM_HERE, base::BindOnce(&NativeDesktopMediaList::UpdateNativeThumbnailsFinished, media_list_)); + diff --git a/patches/chromium/disable_color_correct_rendering.patch b/patches/chromium/disable_color_correct_rendering.patch index a7dab4f37c5..3b66a6f4aa3 100644 --- a/patches/chromium/disable_color_correct_rendering.patch +++ b/patches/chromium/disable_color_correct_rendering.patch @@ -204,10 +204,10 @@ index 1efef99651721d7cdb159ef9fe1aea6c5fb299f0..efcdc1dbe7207f66862a7ab93f0f226c + +#undef PATCH_CS diff --git a/content/browser/gpu/gpu_process_host.cc b/content/browser/gpu/gpu_process_host.cc -index ae8f3b65971935237d98893fcd266ce7d32a625b..75ee5e40bbef5448c7e33457ebc0f3d04698d379 100644 +index 2ed4bf758cdc24de04b1cd37d5b0c0c195e5561d..f87824a4d6cf0f724f4b86c66f9d2a1c7f60b7ca 100644 --- a/content/browser/gpu/gpu_process_host.cc +++ b/content/browser/gpu/gpu_process_host.cc -@@ -210,6 +210,7 @@ GpuTerminationStatus ConvertToGpuTerminationStatus( +@@ -209,6 +209,7 @@ GpuTerminationStatus ConvertToGpuTerminationStatus( // Command-line switches to propagate to the GPU process. static const char* const kSwitchNames[] = { @@ -216,10 +216,10 @@ index ae8f3b65971935237d98893fcd266ce7d32a625b..75ee5e40bbef5448c7e33457ebc0f3d0 service_manager::switches::kGpuSandboxAllowSysVShm, service_manager::switches::kGpuSandboxFailuresFatal, diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc -index 11b18f08dbaba89a483908faef465adfb6bd4019..02b0fa9444c07396aee177b9a5d5bc1c6da5e081 100644 +index 0e84525e677131b3428e5fe73dfb7b48bf65a692..c473f13efc218c98942166715504006d56f9a862 100644 --- a/content/browser/renderer_host/render_process_host_impl.cc +++ b/content/browser/renderer_host/render_process_host_impl.cc -@@ -230,6 +230,7 @@ +@@ -226,6 +226,7 @@ #include "ui/accessibility/accessibility_switches.h" #include "ui/base/ui_base_switches.h" #include "ui/display/display_switches.h" @@ -227,7 +227,7 @@ index 11b18f08dbaba89a483908faef465adfb6bd4019..02b0fa9444c07396aee177b9a5d5bc1c #include "ui/gl/gl_switches.h" #include "ui/native_theme/native_theme_features.h" #include "url/origin.h" -@@ -3252,6 +3253,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer( +@@ -3246,6 +3247,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer( // Propagate the following switches to the renderer command line (along // with any associated values) if present in the browser command line. static const char* const kSwitchNames[] = { @@ -236,7 +236,7 @@ index 11b18f08dbaba89a483908faef465adfb6bd4019..02b0fa9444c07396aee177b9a5d5bc1c service_manager::switches::kDisableInProcessStackTraces, service_manager::switches::kDisableSeccompFilterSandbox, diff --git a/content/renderer/render_widget.cc b/content/renderer/render_widget.cc -index 56397e6a28846508730dfcfe6f0009f944ffd18d..9e8b76407029b3b768c94a16622bcf7df8bd50e2 100644 +index 85dae05a77b3189dac8d506705555dd96eea07a7..523a971c8e2c7a52eb8b7857cc8aa17e5bb9bf85 100644 --- a/content/renderer/render_widget.cc +++ b/content/renderer/render_widget.cc @@ -2548,6 +2548,9 @@ cc::LayerTreeSettings RenderWidget::GenerateLayerTreeSettings( @@ -250,7 +250,7 @@ index 56397e6a28846508730dfcfe6f0009f944ffd18d..9e8b76407029b3b768c94a16622bcf7d // is what the renderer uses if its not threaded. settings.enable_checker_imaging = diff --git a/third_party/blink/renderer/platform/graphics/canvas_color_params.cc b/third_party/blink/renderer/platform/graphics/canvas_color_params.cc -index 570ac93ad8cffda1bf6a8a9847a8052c2daa0d1e..b9ff54463e950c39f282794191e55a721bc7a25a 100644 +index 6bf7541499dd849439f191cfddae92dded99ef85..a023ddd9f8311bff998bb6655445bb44baa96cfc 100644 --- a/third_party/blink/renderer/platform/graphics/canvas_color_params.cc +++ b/third_party/blink/renderer/platform/graphics/canvas_color_params.cc @@ -4,6 +4,7 @@ diff --git a/patches/chromium/disable_hidden.patch b/patches/chromium/disable_hidden.patch index eb07f3165c6..df60225cce6 100644 --- a/patches/chromium/disable_hidden.patch +++ b/patches/chromium/disable_hidden.patch @@ -6,10 +6,10 @@ Subject: disable_hidden.patch Electron uses this to disable background throttling for hidden windows. diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc -index 073eeea86fd18d19320b13b701012cc3518bd4b4..77526d78e8113f7071fe269cbcdf63bb772db6e4 100644 +index a60ee2a3568046caa1a35ad0430d3c244c6e49a3..e660c0e072a6fa855102ec7e4d8a883a923e46ae 100644 --- a/content/browser/renderer_host/render_widget_host_impl.cc +++ b/content/browser/renderer_host/render_widget_host_impl.cc -@@ -646,6 +646,9 @@ void RenderWidgetHostImpl::WasHidden() { +@@ -645,6 +645,9 @@ void RenderWidgetHostImpl::WasHidden() { if (is_hidden_) return; @@ -20,10 +20,10 @@ index 073eeea86fd18d19320b13b701012cc3518bd4b4..77526d78e8113f7071fe269cbcdf63bb blink::mojom::PointerLockResult::kWrongDocument); diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h -index 16d5f4083e5674a561c9e4b0fedd23dd2876c8d0..eed9bac1384df3f1248dd49d092ace3765a6691e 100644 +index 34be0a2ee98bcfc46acc9a9c7202451c72ea9631..294964841b1d3be15ca87c74da27fa4cdc0a8da3 100644 --- a/content/browser/renderer_host/render_widget_host_impl.h +++ b/content/browser/renderer_host/render_widget_host_impl.h -@@ -180,6 +180,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl +@@ -181,6 +181,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl // RenderWidgetHostImpl. static RenderWidgetHostImpl* From(RenderWidgetHost* rwh); @@ -34,7 +34,7 @@ index 16d5f4083e5674a561c9e4b0fedd23dd2876c8d0..eed9bac1384df3f1248dd49d092ace37 const base::TimeDelta& delay) { new_content_rendering_delay_ = delay; diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc -index 45ac5ece9e975b8213845d80a9a309a17eb1de03..e0157ea857cd4cb8984e983e8631f95db90f2fc2 100644 +index 4802fcfbccc628d186c30f9941e5a6a7eeea06a0..099ac6cccd9d7b46d41c3356423f82d863fcca66 100644 --- a/content/browser/renderer_host/render_widget_host_view_aura.cc +++ b/content/browser/renderer_host/render_widget_host_view_aura.cc @@ -641,7 +641,7 @@ void RenderWidgetHostViewAura::HideImpl() { diff --git a/patches/chromium/expose_setuseragent_on_networkcontext.patch b/patches/chromium/expose_setuseragent_on_networkcontext.patch index 04af2da9cb4..1d7b3ee6de9 100644 --- a/patches/chromium/expose_setuseragent_on_networkcontext.patch +++ b/patches/chromium/expose_setuseragent_on_networkcontext.patch @@ -33,10 +33,10 @@ index 0ccfe130f00ec3b6c75cd8ee04d5a2777e1fd00c..653829457d58bf92057cc36aa8a28970 DISALLOW_COPY_AND_ASSIGN(StaticHttpUserAgentSettings); }; diff --git a/services/network/network_context.cc b/services/network/network_context.cc -index e62538f061cccddea14759ea5d92f14b539992fc..6e896ac16194b2a031d012a9ccd5b2726338800d 100644 +index 5f2feba6f09327088badc56d76872d2c3920866f..803315067b4ceccd3ceb3c97ea186b5de7f64f1f 100644 --- a/services/network/network_context.cc +++ b/services/network/network_context.cc -@@ -1013,6 +1013,13 @@ void NetworkContext::SetNetworkConditions( +@@ -1009,6 +1009,13 @@ void NetworkContext::SetNetworkConditions( std::move(network_conditions)); } @@ -51,10 +51,10 @@ index e62538f061cccddea14759ea5d92f14b539992fc..6e896ac16194b2a031d012a9ccd5b272 // This may only be called on NetworkContexts created with the constructor // that calls MakeURLRequestContext(). diff --git a/services/network/network_context.h b/services/network/network_context.h -index 0b35920f4dbaf8fbaf8245c9ae976459c6baa7b8..ef5c5c05bb9b49b13a16421a8cc68fee46e187e8 100644 +index 0bc906026e988819f66554749c8d6aa2f2accc49..b76ab13a2c02b5d61ff931564af743260fbeeae8 100644 --- a/services/network/network_context.h +++ b/services/network/network_context.h -@@ -242,6 +242,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext +@@ -235,6 +235,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext void CloseIdleConnections(CloseIdleConnectionsCallback callback) override; void SetNetworkConditions(const base::UnguessableToken& throttling_profile_id, mojom::NetworkConditionsPtr conditions) override; @@ -63,10 +63,10 @@ index 0b35920f4dbaf8fbaf8245c9ae976459c6baa7b8..ef5c5c05bb9b49b13a16421a8cc68fee void SetEnableReferrers(bool enable_referrers) override; #if defined(OS_CHROMEOS) diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom -index 2b2033797906f36fa829008c65e3b66b6e06eaa2..6ec25efe5bb2819df27d0ba8fc0646f2b80668a8 100644 +index 248108042a5be07a3ddf6a11880ddbf04470d673..2001e6202cf61d1c70bf81334b62d0502ea8c9ba 100644 --- a/services/network/public/mojom/network_context.mojom +++ b/services/network/public/mojom/network_context.mojom -@@ -1049,6 +1049,9 @@ interface NetworkContext { +@@ -1031,6 +1031,9 @@ interface NetworkContext { SetNetworkConditions(mojo_base.mojom.UnguessableToken throttling_profile_id, NetworkConditions? conditions); diff --git a/patches/chromium/feat_allow_disabling_blink_scheduler_throttling_per_renderview.patch b/patches/chromium/feat_allow_disabling_blink_scheduler_throttling_per_renderview.patch index e501a4cf4a3..2fe2b2763a3 100644 --- a/patches/chromium/feat_allow_disabling_blink_scheduler_throttling_per_renderview.patch +++ b/patches/chromium/feat_allow_disabling_blink_scheduler_throttling_per_renderview.patch @@ -6,10 +6,10 @@ Subject: feat: allow disabling blink scheduler throttling per RenderView This allows us to disable throttling for hidden windows. diff --git a/content/browser/renderer_host/render_view_host_impl.cc b/content/browser/renderer_host/render_view_host_impl.cc -index 8c6deced5a7a46623abfdba1d6e1ce5b85c4df33..24664f95f102029f16c084eb7e7574a527c0dbd7 100644 +index 938ff3a2c996a6eb22a1d5913941bf51d9ccebc0..df8c37c8aede6916ef8fb3e85f8c225146555c96 100644 --- a/content/browser/renderer_host/render_view_host_impl.cc +++ b/content/browser/renderer_host/render_view_host_impl.cc -@@ -490,6 +490,10 @@ void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) { +@@ -491,6 +491,10 @@ void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) { GetWidget()->GetAssociatedFrameWidget()->SetBackgroundOpaque(opaque); } @@ -21,10 +21,10 @@ index 8c6deced5a7a46623abfdba1d6e1ce5b85c4df33..24664f95f102029f16c084eb7e7574a5 return is_active(); } diff --git a/content/browser/renderer_host/render_view_host_impl.h b/content/browser/renderer_host/render_view_host_impl.h -index 9d3783d1b990672c5754cdc482af280ec460cc85..ab7d088668f4346e9b76a438663d09108f20d60f 100644 +index dd5cf0829c91f1331ca07a3b799f8351947b05a2..ffb9b0c7e2842ad2d5939264e04e8970a12edf30 100644 --- a/content/browser/renderer_host/render_view_host_impl.h +++ b/content/browser/renderer_host/render_view_host_impl.h -@@ -110,6 +110,7 @@ class CONTENT_EXPORT RenderViewHostImpl +@@ -111,6 +111,7 @@ class CONTENT_EXPORT RenderViewHostImpl SiteInstanceImpl* GetSiteInstance() override; bool IsRenderViewLive() override; void NotifyMoveOrResizeStarted() override; @@ -47,7 +47,7 @@ index 85a8c7e9e283b20ad5ace2f8e02479d1ff212899..ccf8bb322ff8258a7006e4ecbee94bca IPC_MESSAGE_ROUTED1(ViewMsg_UpdateWebPreferences, content::WebPreferences) diff --git a/content/public/browser/render_view_host.h b/content/public/browser/render_view_host.h -index 893c45a5c71b4e55ea323ae60e11d12ddb099efd..db9a1ff0fe1a912db83692ab17c620cff7446bcb 100644 +index dfd856eb481114fea9da3e26b4080c9a8473acf6..604a95a0427705eca523e91b08a136f806da68f0 100644 --- a/content/public/browser/render_view_host.h +++ b/content/public/browser/render_view_host.h @@ -96,6 +96,9 @@ class CONTENT_EXPORT RenderViewHost : public IPC::Sender { @@ -61,10 +61,10 @@ index 893c45a5c71b4e55ea323ae60e11d12ddb099efd..db9a1ff0fe1a912db83692ab17c620cf // // Returns the current WebKit preferences. Note: WebPreferences is cached, so diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc -index 00333d9aa46d643bf65db07cfac7a3a8959a14a3..5a389d142d809ac8835c85a4d35fa1f7e1311e22 100644 +index 80278388015825fee05771aff7af3376d327058a..c681eb0fb52c0db810d1bb23f06929fd71873089 100644 --- a/content/renderer/render_view_impl.cc +++ b/content/renderer/render_view_impl.cc -@@ -1181,6 +1181,8 @@ bool RenderViewImpl::OnMessageReceived(const IPC::Message& message) { +@@ -1180,6 +1180,8 @@ bool RenderViewImpl::OnMessageReceived(const IPC::Message& message) { bool handled = true; IPC_BEGIN_MESSAGE_MAP(RenderViewImpl, message) @@ -73,7 +73,7 @@ index 00333d9aa46d643bf65db07cfac7a3a8959a14a3..5a389d142d809ac8835c85a4d35fa1f7 IPC_MESSAGE_HANDLER(ViewMsg_UpdateTargetURL_ACK, OnUpdateTargetURLAck) IPC_MESSAGE_HANDLER(ViewMsg_UpdateWebPreferences, OnUpdateWebPreferences) IPC_MESSAGE_HANDLER(ViewMsg_MoveOrResizeStarted, OnMoveOrResizeStarted) -@@ -1685,6 +1687,12 @@ bool RenderViewImpl::GetContentStateImmediately() { +@@ -1680,6 +1682,12 @@ bool RenderViewImpl::GetContentStateImmediately() { return send_content_state_immediately_; } @@ -87,7 +87,7 @@ index 00333d9aa46d643bf65db07cfac7a3a8959a14a3..5a389d142d809ac8835c85a4d35fa1f7 webkit_preferences_ = prefs; ApplyWebPreferences(webkit_preferences_, GetWebView()); diff --git a/content/renderer/render_view_impl.h b/content/renderer/render_view_impl.h -index 3ee43ead214b826d158026feac0aeb21767b2543..253bd39e0c5f5e10d04b614ca4a4b4b141d4b2ca 100644 +index dac8651a96409c60684a99a7cf4d735b40decc33..438d0f79767665cc851115970525909d623a582d 100644 --- a/content/renderer/render_view_impl.h +++ b/content/renderer/render_view_impl.h @@ -392,6 +392,7 @@ class CONTENT_EXPORT RenderViewImpl : public blink::WebViewClient, @@ -99,7 +99,7 @@ index 3ee43ead214b826d158026feac0aeb21767b2543..253bd39e0c5f5e10d04b614ca4a4b4b1 void OnUpdateTargetURLAck(); void OnUpdateWebPreferences(const WebPreferences& prefs); diff --git a/third_party/blink/public/web/web_view.h b/third_party/blink/public/web/web_view.h -index 2403a3d668c807a930e163a1282cb6463c14094c..a0eb764c56d5a0d4e7eb4a21a9d734ffd6ddedd0 100644 +index 53faedcea05f045e42b87bf13db5961964f9c298..851409ebf365e74e4b2c9de4a658f67f3062052a 100644 --- a/third_party/blink/public/web/web_view.h +++ b/third_party/blink/public/web/web_view.h @@ -380,6 +380,7 @@ class WebView { @@ -111,10 +111,10 @@ index 2403a3d668c807a930e163a1282cb6463c14094c..a0eb764c56d5a0d4e7eb4a21a9d734ff // Visibility ----------------------------------------------------------- diff --git a/third_party/blink/renderer/core/exported/web_view_impl.cc b/third_party/blink/renderer/core/exported/web_view_impl.cc -index f593e3d5c95b5ea5fb6543500ad0d1902c349830..0acd8981a2d4da85eaa9bc13858fd0454681c248 100644 +index 78b796cc46c479525b1c99ee39ed9576efc17d5b..d1b65d3570d1ad218cc8447e0ab9422306d7f2f4 100644 --- a/third_party/blink/renderer/core/exported/web_view_impl.cc +++ b/third_party/blink/renderer/core/exported/web_view_impl.cc -@@ -3290,6 +3290,13 @@ PageScheduler* WebViewImpl::Scheduler() const { +@@ -3342,6 +3342,13 @@ PageScheduler* WebViewImpl::Scheduler() const { return GetPage()->GetPageScheduler(); } @@ -128,7 +128,7 @@ index f593e3d5c95b5ea5fb6543500ad0d1902c349830..0acd8981a2d4da85eaa9bc13858fd045 void WebViewImpl::SetVisibilityState( mojom::blink::PageVisibilityState visibility_state, bool is_initial_state) { -@@ -3300,7 +3307,8 @@ void WebViewImpl::SetVisibilityState( +@@ -3352,7 +3359,8 @@ void WebViewImpl::SetVisibilityState( } GetPage()->SetVisibilityState(visibility_state, is_initial_state); GetPage()->GetPageScheduler()->SetPageVisible( @@ -139,10 +139,10 @@ index f593e3d5c95b5ea5fb6543500ad0d1902c349830..0acd8981a2d4da85eaa9bc13858fd045 mojom::blink::PageVisibilityState WebViewImpl::GetVisibilityState() { diff --git a/third_party/blink/renderer/core/exported/web_view_impl.h b/third_party/blink/renderer/core/exported/web_view_impl.h -index cce7153c37c33e4fe5ada710dcccc56471a10bca..35defe5d1eef12e66f050321dcf776c1853788b9 100644 +index 4ee975c80501c77e5bf7d599a69983a62a07989d..c5d174f045f8f9d6225aadc70dfe13ceca408dd4 100644 --- a/third_party/blink/renderer/core/exported/web_view_impl.h +++ b/third_party/blink/renderer/core/exported/web_view_impl.h -@@ -323,6 +323,7 @@ class CORE_EXPORT WebViewImpl final : public WebView, +@@ -325,6 +325,7 @@ class CORE_EXPORT WebViewImpl final : public WebView, LocalDOMWindow* PagePopupWindow() const; PageScheduler* Scheduler() const override; @@ -150,7 +150,7 @@ index cce7153c37c33e4fe5ada710dcccc56471a10bca..35defe5d1eef12e66f050321dcf776c1 void SetVisibilityState(mojom::blink::PageVisibilityState visibility_state, bool is_initial_state) override; mojom::blink::PageVisibilityState GetVisibilityState() override; -@@ -683,6 +684,8 @@ class CORE_EXPORT WebViewImpl final : public WebView, +@@ -681,6 +682,8 @@ class CORE_EXPORT WebViewImpl final : public WebView, // WebViewImpl::Close while handling an input event. bool debug_inside_input_handling_ = false; diff --git a/patches/chromium/feat_enable_offscreen_rendering_with_viz_compositor.patch b/patches/chromium/feat_enable_offscreen_rendering_with_viz_compositor.patch index 15473d5ee34..fbd357a87c4 100644 --- a/patches/chromium/feat_enable_offscreen_rendering_with_viz_compositor.patch +++ b/patches/chromium/feat_enable_offscreen_rendering_with_viz_compositor.patch @@ -455,10 +455,10 @@ index 2bb30e5318b6b48c2e6d4b1f64a6a36c68f963d1..9e805f27a9d7d1c0aa68cdf9f48895c0 waiting_on_draw_ack_ = true; diff --git a/content/browser/compositor/viz_process_transport_factory.cc b/content/browser/compositor/viz_process_transport_factory.cc -index ffb3a04236be821e7ba1c7370258eb0610497c8e..5fd16e51508dc3227798a7166226ff5d01dcd921 100644 +index 0e1b4bf9d45582dcfa8882b73e4cd239baa0b1f1..645b4359f49e931f769d6ea7e3be98e8a70dd3f0 100644 --- a/content/browser/compositor/viz_process_transport_factory.cc +++ b/content/browser/compositor/viz_process_transport_factory.cc -@@ -404,8 +404,13 @@ void VizProcessTransportFactory::OnEstablishedGpuChannel( +@@ -403,8 +403,13 @@ void VizProcessTransportFactory::OnEstablishedGpuChannel( compositor_data.display_private.reset(); root_params->display_private = compositor_data.display_private.BindNewEndpointAndPassReceiver(); @@ -527,7 +527,7 @@ index 6b7fbb6cf13dc8ee6ade0878a9a2c1efc5d4d3f1..e2af75168cb914a7b3b4a6c9b6a28549 + Draw(gfx.mojom.Rect damage_rect) => (); }; diff --git a/ui/compositor/compositor.h b/ui/compositor/compositor.h -index 48cd5ff63d76899b24e460bc2b074fa6b2e38fd2..434be7569f45e21d2b3e95fc80a6b5bc1f4ce316 100644 +index e47736aae80be8433fdb5afd4678efde1a60e6d4..de0560a32863d2bd5089aadcfd74202a6fe2b560 100644 --- a/ui/compositor/compositor.h +++ b/ui/compositor/compositor.h @@ -74,6 +74,7 @@ class DisplayPrivate; @@ -564,7 +564,7 @@ index 48cd5ff63d76899b24e460bc2b074fa6b2e38fd2..434be7569f45e21d2b3e95fc80a6b5bc // Sets the root of the layer tree drawn by this Compositor. The root layer // must have no parent. The compositor's root layer is reset if the root layer // is destroyed. NULL can be passed to reset the root layer, in which case the -@@ -417,6 +430,8 @@ class COMPOSITOR_EXPORT Compositor : public cc::LayerTreeHostClient, +@@ -419,6 +432,8 @@ class COMPOSITOR_EXPORT Compositor : public cc::LayerTreeHostClient, std::unique_ptr pending_begin_frame_args_; diff --git a/patches/chromium/fix_account_for_print_preview_disabled_when_printing_to_pdf.patch b/patches/chromium/fix_account_for_print_preview_disabled_when_printing_to_pdf.patch index 96aadc8282a..081b0055d1e 100644 --- a/patches/chromium/fix_account_for_print_preview_disabled_when_printing_to_pdf.patch +++ b/patches/chromium/fix_account_for_print_preview_disabled_when_printing_to_pdf.patch @@ -10,10 +10,10 @@ understanding, it seems like we slightly misuse the print preview API and this is fallout from using it in a way the code doesn't expect. diff --git a/components/printing/renderer/print_render_frame_helper.cc b/components/printing/renderer/print_render_frame_helper.cc -index 1db0c6cad6cc27b3a548b78d701d2ada7023dad1..3078f6c976086eeef6bc76efd490832c8798d6ce 100644 +index e566b1d22a5bb0aa40f15db83f1dc89e9099f62c..8e8663d561d3ee1956ba5e980c23172bf784d080 100644 --- a/components/printing/renderer/print_render_frame_helper.cc +++ b/components/printing/renderer/print_render_frame_helper.cc -@@ -1495,6 +1495,7 @@ PrintRenderFrameHelper::CreatePreviewDocument() { +@@ -1494,6 +1494,7 @@ PrintRenderFrameHelper::CreatePreviewDocument() { const std::vector& pages = print_pages_params_->pages; bool require_document_metafile = diff --git a/patches/chromium/fix_route_mouse_event_navigations_through_the_web_contents_delegate.patch b/patches/chromium/fix_route_mouse_event_navigations_through_the_web_contents_delegate.patch index 8984f1cd06d..9aa2cb0a12a 100644 --- a/patches/chromium/fix_route_mouse_event_navigations_through_the_web_contents_delegate.patch +++ b/patches/chromium/fix_route_mouse_event_navigations_through_the_web_contents_delegate.patch @@ -13,10 +13,10 @@ This patch can be removed once app.allowRendererProcessReuse is forced to true as then Chromiums assumptions around processes become correct. diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc -index c017455770707877008e2df07e65c391068bdb8c..31b30a3f729258accab5a135eeddba7b79990e81 100644 +index e282718ec461f6c7bcb1fe36d5bb73359f04a30a..725e9f890bf5479d4435b9e7366b8fe2a10e0919 100644 --- a/content/browser/web_contents/web_contents_impl.cc +++ b/content/browser/web_contents/web_contents_impl.cc -@@ -2368,11 +2368,13 @@ bool WebContentsImpl::HandleMouseEvent(const blink::WebMouseEvent& event) { +@@ -2385,11 +2385,13 @@ bool WebContentsImpl::HandleMouseEvent(const blink::WebMouseEvent& event) { WebContentsImpl* outermost = GetOutermostWebContents(); if (event.button == blink::WebPointerProperties::Button::kBack && outermost->controller_.CanGoBack()) { diff --git a/patches/chromium/fix_xserver_crash_when_using_xwindow_setxwindowicons.patch b/patches/chromium/fix_xserver_crash_when_using_xwindow_setxwindowicons.patch deleted file mode 100644 index acc18cacaeb..00000000000 --- a/patches/chromium/fix_xserver_crash_when_using_xwindow_setxwindowicons.patch +++ /dev/null @@ -1,63 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: deepak1556 -Date: Fri, 22 May 2020 12:05:07 -0700 -Subject: Fix XServer crash when using XWindow::SetXWindowIcons - -This patch should be removed once https://bugs.chromium.org/p/chromium/issues/detail?id=1085836 -is addressed. - -diff --git a/ui/base/x/x11_window.cc b/ui/base/x/x11_window.cc -index 03282473ab22d2669d1b7ba9ada3ec483748dc57..b67f8104bd9f9b1dc517654f8658487c84d9a032 100644 ---- a/ui/base/x/x11_window.cc -+++ b/ui/base/x/x11_window.cc -@@ -64,17 +64,17 @@ gfx::Rect SanitizeBounds(const gfx::Rect& bounds) { - } - - void SerializeImageRepresentation(const gfx::ImageSkiaRep& rep, -- std::vector* data) { -- uint32_t width = rep.GetWidth(); -+ std::vector* data) { -+ int width = rep.GetWidth(); - data->push_back(width); - -- uint32_t height = rep.GetHeight(); -+ int height = rep.GetHeight(); - data->push_back(height); - - const SkBitmap& bitmap = rep.GetBitmap(); - -- for (uint32_t y = 0; y < height; ++y) -- for (uint32_t x = 0; x < width; ++x) -+ for (int y = 0; y < height; ++y) -+ for (int x = 0; x < width; ++x) - data->push_back(bitmap.getColor(x, y)); - } - -@@ -787,7 +787,7 @@ void XWindow::SetXWindowIcons(const gfx::ImageSkia& window_icon, - // so that we can pass to the WM. - // - // All of this could be made much, much better. -- std::vector data; -+ std::vector data; - - if (!window_icon.isNull()) - SerializeImageRepresentation(window_icon.GetRepresentation(1.0f), &data); -@@ -796,8 +796,16 @@ void XWindow::SetXWindowIcons(const gfx::ImageSkia& window_icon, - SerializeImageRepresentation(app_icon.GetRepresentation(1.0f), &data); - - if (!data.empty()) { -- ui::SetArrayProperty(xwindow_, gfx::GetAtom("_NET_WM_ICON"), -- x11::Atom::CARDINAL, data); -+ // XChangeProperty() expects values of type 32 to be longs. -+ std::unique_ptr value(new Atom[data.size()]); -+ for (size_t i = 0; i < data.size(); ++i) -+ value[i] = data[i]; -+ XChangeProperty( -+ gfx::GetXDisplay(), xwindow_, -+ XInternAtom(gfx::GetXDisplay(), "_NET_WM_ICON", x11::False), -+ XA_CARDINAL, 32, PropModeReplace, -+ reinterpret_cast(value.get()), -+ data.size()); - } - } - diff --git a/patches/chromium/frame_host_manager.patch b/patches/chromium/frame_host_manager.patch index f048036dc9a..e4d5b9d1b16 100644 --- a/patches/chromium/frame_host_manager.patch +++ b/patches/chromium/frame_host_manager.patch @@ -42,10 +42,10 @@ index 06f0961e122f326e41610dd7a1b32fa752f0c68f..a041189f79cea5b59e1792b79c1348e3 // another SiteInstance for the same site. void RegisterSiteInstance(SiteInstanceImpl* site_instance); diff --git a/content/browser/frame_host/navigation_request.cc b/content/browser/frame_host/navigation_request.cc -index f81f412ed1b8c238adb6d0635cd23b1e1da50090..d77d6ee893b2481b2748c7931189be8b18301174 100644 +index fa3ed4e33b4fbe274738442f22e07ba233056ce8..e8e4eb7963b443b95e98a173df497d1662f9226b 100644 --- a/content/browser/frame_host/navigation_request.cc +++ b/content/browser/frame_host/navigation_request.cc -@@ -1275,6 +1275,24 @@ void NavigationRequest::BeginNavigation() { +@@ -1278,6 +1278,24 @@ void NavigationRequest::BeginNavigation() { // it immediately. EnterChildTraceEvent("ResponseStarted", this); @@ -71,10 +71,10 @@ index f81f412ed1b8c238adb6d0635cd23b1e1da50090..d77d6ee893b2481b2748c7931189be8b render_frame_host_ = frame_tree_node_->render_manager()->GetFrameHostForNavigation(this); diff --git a/content/browser/frame_host/render_frame_host_manager.cc b/content/browser/frame_host/render_frame_host_manager.cc -index 98475dc9b06182951a473c9d33fcbd23fe4892db..646cbacbdaaf33be896c9fee3259d0779f03c451 100644 +index 829a14c0cc306fa74c80b7c123ddaa309c0c18c9..49a47e1f8d1fc4161684a13b6fdaceb6762234ad 100644 --- a/content/browser/frame_host/render_frame_host_manager.cc +++ b/content/browser/frame_host/render_frame_host_manager.cc -@@ -2406,6 +2406,16 @@ bool RenderFrameHostManager::InitRenderView( +@@ -2464,6 +2464,16 @@ bool RenderFrameHostManager::InitRenderView( scoped_refptr RenderFrameHostManager::GetSiteInstanceForNavigationRequest( NavigationRequest* request) { @@ -91,7 +91,7 @@ index 98475dc9b06182951a473c9d33fcbd23fe4892db..646cbacbdaaf33be896c9fee3259d077 SiteInstance* current_site_instance = render_frame_host_->GetSiteInstance(); // All children of MHTML documents must be MHTML documents. They all live in -@@ -2425,10 +2435,60 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest( +@@ -2483,10 +2493,60 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest( // // TODO(clamy): We should also consider as a candidate SiteInstance the // speculative SiteInstance that was computed on redirects. @@ -156,7 +156,7 @@ index 98475dc9b06182951a473c9d33fcbd23fe4892db..646cbacbdaaf33be896c9fee3259d077 // Account for renderer-initiated reload as well. // Needed as a workaround for https://crbug.com/1045524, remove it when it is -@@ -2493,6 +2553,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest( +@@ -2551,6 +2611,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest( request->ResetStateForSiteInstanceChange(); } @@ -194,7 +194,7 @@ index 10dd6f03af22bd7d0f7b65a58d4a58430c129b49..88504adb27e6461648f7dce48c93e2e1 size_t GetRelatedActiveContentsCount() override; bool RequiresDedicatedProcess() override; diff --git a/content/public/browser/content_browser_client.cc b/content/public/browser/content_browser_client.cc -index 3c743a74321d54e36248d7b6201d9fdf5b749af6..13418cab6cce233a14110eca7a887eb549cf438b 100644 +index 8f36f7277a59d297a0700d1dfd5d8120f6a0ffa1..4858b868972c02f580789a6e396fd5db52154bad 100644 --- a/content/public/browser/content_browser_client.cc +++ b/content/public/browser/content_browser_client.cc @@ -59,6 +59,21 @@ @@ -220,7 +220,7 @@ index 3c743a74321d54e36248d7b6201d9fdf5b749af6..13418cab6cce233a14110eca7a887eb5 const MainFunctionParams& parameters) { return nullptr; diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h -index 491d6e7260dd329f312916c2f4aaba0aa177cc6a..a9119a722935a8320e463e2e24cdd39b9e8b1773 100644 +index 463fcc56d05a2e18c1d3752b5e7e275c8797eca8..df1e5d1ed6e9e40ac14f1aef289801b6d63fa78d 100644 --- a/content/public/browser/content_browser_client.h +++ b/content/public/browser/content_browser_client.h @@ -236,8 +236,45 @@ class CONTENT_EXPORT ContentBrowserClient { diff --git a/patches/chromium/gpu_notify_when_dxdiag_request_fails.patch b/patches/chromium/gpu_notify_when_dxdiag_request_fails.patch index d9e316d7eeb..261248e0036 100644 --- a/patches/chromium/gpu_notify_when_dxdiag_request_fails.patch +++ b/patches/chromium/gpu_notify_when_dxdiag_request_fails.patch @@ -40,10 +40,10 @@ index ce8f9551f1b17c7508a0e0bd0ecc55eca2c0ac6e..2e71ce71ff9f18e2fc68f51ddbeedc39 // Update the GPU feature info. This updates the blacklist and enabled status // of GPU rasterization. In the future this will be used for more features. diff --git a/content/browser/gpu/gpu_data_manager_impl_private.cc b/content/browser/gpu/gpu_data_manager_impl_private.cc -index e4ebd7fcd4a1b9045552e72fef23cd5cc7941b5b..8c52a512c272a19edb0076efe22473928ddc1522 100644 +index f65d5d0eb7d10ec6887fc156d23ab948e10c1bc3..0e34fb12f6e08039fb541890ee869c1ad1e08948 100644 --- a/content/browser/gpu/gpu_data_manager_impl_private.cc +++ b/content/browser/gpu/gpu_data_manager_impl_private.cc -@@ -923,6 +923,10 @@ void GpuDataManagerImplPrivate::TerminateInfoCollectionGpuProcess() { +@@ -922,6 +922,10 @@ void GpuDataManagerImplPrivate::TerminateInfoCollectionGpuProcess() { host->ForceShutdown(); } diff --git a/patches/chromium/hack_plugin_response_interceptor_to_point_to_electron.patch b/patches/chromium/hack_plugin_response_interceptor_to_point_to_electron.patch index fb917242172..e8d3cfa67bc 100644 --- a/patches/chromium/hack_plugin_response_interceptor_to_point_to_electron.patch +++ b/patches/chromium/hack_plugin_response_interceptor_to_point_to_electron.patch @@ -8,13 +8,13 @@ require a largeish patch to get working, so just redirect it to our implementation instead. diff --git a/chrome/browser/plugins/plugin_response_interceptor_url_loader_throttle.cc b/chrome/browser/plugins/plugin_response_interceptor_url_loader_throttle.cc -index 6d6a5fa9530d2a7309c46385b853af42bd25569f..bbb7789cb89a23eea592179d23379cff2fedbefa 100644 +index a692d5e33cfdad762eb0c59c6e14fab2675c603b..121424e9523a7977be64cbcd5b99ccb2947dff7e 100644 --- a/chrome/browser/plugins/plugin_response_interceptor_url_loader_throttle.cc +++ b/chrome/browser/plugins/plugin_response_interceptor_url_loader_throttle.cc -@@ -10,8 +10,8 @@ +@@ -9,8 +9,8 @@ + #include "base/bind.h" #include "base/feature_list.h" #include "base/guid.h" - #include "base/task/post_task.h" -#include "chrome/browser/extensions/api/streams_private/streams_private_api.h" -#include "chrome/browser/plugins/plugin_utils.h" +#include "electron/shell/browser/extensions/api/streams_private/streams_private_api.h" diff --git a/patches/chromium/mas_disable_custom_window_frame.patch b/patches/chromium/mas_disable_custom_window_frame.patch index 4acb20b02f9..e4f2b279752 100644 --- a/patches/chromium/mas_disable_custom_window_frame.patch +++ b/patches/chromium/mas_disable_custom_window_frame.patch @@ -95,10 +95,10 @@ index e03bbc724cfd01967e71998394361556df1c4915..783745b11365c04c1e1052197d20d494 // The NSWindow used by BridgedNativeWidget. Provides hooks into AppKit that // can only be accomplished by overriding methods. diff --git a/components/remote_cocoa/app_shim/native_widget_mac_nswindow.mm b/components/remote_cocoa/app_shim/native_widget_mac_nswindow.mm -index 5e5a39c2920b748823d21f15bc054733d7aa6441..980c4cef13bacb46e92264bf38f3934626515190 100644 +index 757c72d98de11f611309f4f5af8d0d9aab639181..a6319a0760308df6bac6b39ad3500ad77c1b6525 100644 --- a/components/remote_cocoa/app_shim/native_widget_mac_nswindow.mm +++ b/components/remote_cocoa/app_shim/native_widget_mac_nswindow.mm -@@ -15,7 +15,9 @@ +@@ -16,7 +16,9 @@ #import "ui/base/cocoa/window_size_constants.h" @interface NSWindow (Private) @@ -108,7 +108,7 @@ index 5e5a39c2920b748823d21f15bc054733d7aa6441..980c4cef13bacb46e92264bf38f39346 - (BOOL)hasKeyAppearance; - (long long)_resizeDirectionForMouseLocation:(CGPoint)location; - (BOOL)_isConsideredOpenForPersistentState; -@@ -57,6 +59,8 @@ +@@ -58,6 +60,8 @@ } @end @@ -116,8 +116,8 @@ index 5e5a39c2920b748823d21f15bc054733d7aa6441..980c4cef13bacb46e92264bf38f39346 + @implementation NativeWidgetMacNSWindowTitledFrame - (void)mouseDown:(NSEvent*)event { - if (self.window.isMovable) -@@ -83,6 +87,8 @@ + if (base::mac::IsAtMostOS10_11() && self.window.isMovable) +@@ -84,6 +88,8 @@ } @end @@ -126,7 +126,7 @@ index 5e5a39c2920b748823d21f15bc054733d7aa6441..980c4cef13bacb46e92264bf38f39346 @implementation NativeWidgetMacNSWindow { @private base::scoped_nsobject _commandDispatcher; -@@ -164,6 +170,8 @@ +@@ -165,6 +171,8 @@ // NSWindow overrides. @@ -135,7 +135,7 @@ index 5e5a39c2920b748823d21f15bc054733d7aa6441..980c4cef13bacb46e92264bf38f39346 + (Class)frameViewClassForStyleMask:(NSWindowStyleMask)windowStyle { if (windowStyle & NSWindowStyleMaskTitled) { if (Class customFrame = [NativeWidgetMacNSWindowTitledFrame class]) -@@ -175,6 +183,8 @@ +@@ -176,6 +184,8 @@ return [super frameViewClassForStyleMask:windowStyle]; } diff --git a/patches/chromium/mas_disable_remote_layer.patch b/patches/chromium/mas_disable_remote_layer.patch index ee3a78d2d75..219210aefb4 100644 --- a/patches/chromium/mas_disable_remote_layer.patch +++ b/patches/chromium/mas_disable_remote_layer.patch @@ -17,7 +17,7 @@ cases where performance improves when disabling remote CoreAnimation (remote CoreAnimation is really only about battery usage). diff --git a/gpu/ipc/service/image_transport_surface_overlay_mac.h b/gpu/ipc/service/image_transport_surface_overlay_mac.h -index a298747e3b755acd4f8d366d625142371ed1995e..9c9bdc53016637c6d6dbb27f3581b343ec96fb97 100644 +index 3307998ec566e24a9050434af4e6e3bb09557d43..456603c97bfc2214b0d08fecd592ff1e2c26ceb6 100644 --- a/gpu/ipc/service/image_transport_surface_overlay_mac.h +++ b/gpu/ipc/service/image_transport_surface_overlay_mac.h @@ -20,7 +20,9 @@ @@ -30,7 +30,7 @@ index a298747e3b755acd4f8d366d625142371ed1995e..9c9bdc53016637c6d6dbb27f3581b343 @class CALayer; namespace ui { -@@ -97,7 +99,9 @@ class ImageTransportSurfaceOverlayMacBase : public BaseClass, +@@ -111,7 +113,9 @@ class ImageTransportSurfaceOverlayMacBase : public BaseClass, base::WeakPtr delegate_; bool use_remote_layer_api_; @@ -41,7 +41,7 @@ index a298747e3b755acd4f8d366d625142371ed1995e..9c9bdc53016637c6d6dbb27f3581b343 gfx::Size pixel_size_; diff --git a/gpu/ipc/service/image_transport_surface_overlay_mac.mm b/gpu/ipc/service/image_transport_surface_overlay_mac.mm -index eb46993b8f40fdc7da35dae1b850dad637f6b47d..05a9ae47620d17b5a53f991c0b3a0a5c153b599c 100644 +index 7c97709a8dfe55fb91b5bdae3f7a83d8bdf93f1b..77d930293ff0b552a504464898ed809067b2cac0 100644 --- a/gpu/ipc/service/image_transport_surface_overlay_mac.mm +++ b/gpu/ipc/service/image_transport_surface_overlay_mac.mm @@ -63,6 +63,7 @@ ImageTransportSurfaceOverlayMacBase< @@ -60,7 +60,7 @@ index eb46993b8f40fdc7da35dae1b850dad637f6b47d..05a9ae47620d17b5a53f991c0b3a0a5c return true; } -@@ -139,7 +141,9 @@ ImageTransportSurfaceOverlayMacBase::SwapBuffersInternal( +@@ -140,7 +142,9 @@ ImageTransportSurfaceOverlayMacBase::SwapBuffersInternal( "GLImpl", static_cast(gl::GetGLImplementation()), "width", pixel_size_.width()); if (use_remote_layer_api_) { diff --git a/patches/chromium/mas_no_private_api.patch b/patches/chromium/mas_no_private_api.patch index 69915055577..535a08b4336 100644 --- a/patches/chromium/mas_no_private_api.patch +++ b/patches/chromium/mas_no_private_api.patch @@ -50,7 +50,7 @@ index 5124b17f020849671a7f03d92bda052eff84d169..f9730f71c122965f7ce7815a1b9a7b32 // is concerned. @property(nonatomic, readonly) NSString* subrole; diff --git a/content/browser/accessibility/browser_accessibility_cocoa.mm b/content/browser/accessibility/browser_accessibility_cocoa.mm -index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce03e97c09 100644 +index a35b6dae73540518443a4b4d5745178e248c64f0..38ca03b2365e0d3a2c15abda6fb05256851deb57 100644 --- a/content/browser/accessibility/browser_accessibility_cocoa.mm +++ b/content/browser/accessibility/browser_accessibility_cocoa.mm @@ -206,6 +206,7 @@ NSString* const @@ -124,7 +124,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce {NSAccessibilitySizeAttribute, @"size"}, {NSAccessibilitySortDirectionAttribute, @"sortDirection"}, {NSAccessibilitySubroleAttribute, @"subrole"}, -@@ -1289,6 +1301,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -1290,6 +1302,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; ax::mojom::Restriction::kDisabled]; } @@ -132,7 +132,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce // Returns a text marker that points to the last character in the document that // can be selected with VoiceOver. - (id)endTextMarker { -@@ -1299,6 +1312,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -1300,6 +1313,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; BrowserAccessibilityPositionInstance position = root->CreatePositionAt(0); return CreateTextMarker(position->CreatePositionAtEndOfAnchor()); } @@ -140,7 +140,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce - (NSNumber*)expanded { if (![self instanceActive]) -@@ -1448,6 +1462,8 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -1449,6 +1463,8 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; return nil; } @@ -149,7 +149,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce - (NSNumber*)insertionPointLineNumber { if (![self instanceActive]) return nil; -@@ -1470,6 +1486,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -1471,6 +1487,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; caretPosition->AsTextPosition()->text_offset()); return @(std::distance(lineBreaks.begin(), iterator)); } @@ -157,7 +157,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce // Returns whether or not this node should be ignored in the // accessibility tree. -@@ -2146,6 +2163,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -2147,6 +2164,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; return ret; } @@ -165,7 +165,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce - (NSString*)selectedText { if (![self instanceActive]) return nil; -@@ -2157,11 +2175,13 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -2158,11 +2176,13 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; return nil; return base::SysUTF16ToNSString(range.GetText()); } @@ -179,7 +179,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce - (NSValue*)selectedTextRange { if (![self instanceActive]) return nil; -@@ -2182,12 +2202,15 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -2183,12 +2203,15 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; int selLength = range.GetText().length(); return [NSValue valueWithRange:NSMakeRange(selStart, selLength)]; } @@ -195,7 +195,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce - (NSValue*)size { if (![self instanceActive]) -@@ -2220,6 +2243,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -2221,6 +2244,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; return nil; } @@ -203,7 +203,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce // Returns a text marker that points to the first character in the document that // can be selected with VoiceOver. - (id)startTextMarker { -@@ -2230,6 +2254,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -2231,6 +2255,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; BrowserAccessibilityPositionInstance position = root->CreatePositionAt(0); return CreateTextMarker(position->CreatePositionAtStartOfAnchor()); } @@ -211,7 +211,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce // Returns a subrole based upon the role. - (NSString*)subrole { -@@ -2552,11 +2577,13 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -2553,11 +2578,13 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; NSMutableAttributedString* attributedInnerText = [[[NSMutableAttributedString alloc] initWithString:base::SysUTF16ToNSString(innerText)] autorelease]; @@ -225,7 +225,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce return [attributedInnerText attributedSubstringFromRange:range]; } -@@ -2660,9 +2687,8 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -2661,9 +2688,8 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; return ToBrowserAccessibilityCocoa(cell); } @@ -237,7 +237,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce BrowserAccessibilityPositionInstance position = CreatePositionFromTextMarker(parameter); if (!position->IsNullPosition()) -@@ -2975,6 +3001,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -2976,6 +3002,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; return CreateTextMarker(root->CreatePositionAt(index)); } @@ -245,7 +245,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce if ([attribute isEqualToString: NSAccessibilityBoundsForRangeParameterizedAttribute]) { -@@ -3010,6 +3037,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -3011,6 +3038,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; return nil; } @@ -253,7 +253,7 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce if ([attribute isEqualToString: NSAccessibilityLineTextMarkerRangeForTextMarkerParameterizedAttribute]) { -@@ -3124,6 +3152,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; +@@ -3125,6 +3153,7 @@ NSString* const NSAccessibilityRequiredAttributeChrome = @"AXRequired"; return @(child->GetIndexInParent()); } @@ -262,10 +262,10 @@ index 558839d8847479cb10e747576a2d0cd57701bda0..975054ba2605dae54800e6d087f9d1ce return nil; } diff --git a/content/browser/accessibility/browser_accessibility_manager_mac.mm b/content/browser/accessibility/browser_accessibility_manager_mac.mm -index 07645b4165bedc04eb83f7e736ab1254e5b2901d..f69c39341af7ef87f2c6aab8954b748ff9d3ec0e 100644 +index 83d0106f0f237dea75dfafe011bf527d97240d0d..462577a0dbd0fcc1baf17acd9678317cb27503fa 100644 --- a/content/browser/accessibility/browser_accessibility_manager_mac.mm +++ b/content/browser/accessibility/browser_accessibility_manager_mac.mm -@@ -526,6 +526,7 @@ NSDictionary* BrowserAccessibilityManagerMac:: +@@ -525,6 +525,7 @@ NSDictionary* BrowserAccessibilityManagerMac:: [user_info setObject:native_focus_object forKey:NSAccessibilityTextChangeElement]; @@ -273,7 +273,7 @@ index 07645b4165bedc04eb83f7e736ab1254e5b2901d..f69c39341af7ef87f2c6aab8954b748f id selected_text = [native_focus_object selectedTextMarkerRange]; if (selected_text) { NSString* const NSAccessibilitySelectedTextMarkerRangeAttribute = -@@ -533,6 +534,7 @@ NSDictionary* BrowserAccessibilityManagerMac:: +@@ -532,6 +533,7 @@ NSDictionary* BrowserAccessibilityManagerMac:: [user_info setObject:selected_text forKey:NSAccessibilitySelectedTextMarkerRangeAttribute]; } diff --git a/patches/chromium/network_service_allow_remote_certificate_verification_logic.patch b/patches/chromium/network_service_allow_remote_certificate_verification_logic.patch index 24a541c6e8c..af335ad26f8 100644 --- a/patches/chromium/network_service_allow_remote_certificate_verification_logic.patch +++ b/patches/chromium/network_service_allow_remote_certificate_verification_logic.patch @@ -7,7 +7,7 @@ This adds a callback from the network service that's used to implement session.setCertificateVerifyCallback. diff --git a/services/network/network_context.cc b/services/network/network_context.cc -index 2c3f75ea4ad177a63d64081f5d8028b60771edb8..e62538f061cccddea14759ea5d92f14b539992fc 100644 +index 3cd537df5ee9b1c9da6571c63c0058b5a9b820fa..5f2feba6f09327088badc56d76872d2c3920866f 100644 --- a/services/network/network_context.cc +++ b/services/network/network_context.cc @@ -111,6 +111,11 @@ @@ -102,7 +102,7 @@ index 2c3f75ea4ad177a63d64081f5d8028b60771edb8..e62538f061cccddea14759ea5d92f14b constexpr uint32_t NetworkContext::kMaxOutstandingRequestsPerProcess; NetworkContext::PendingCertVerify::PendingCertVerify() = default; -@@ -496,6 +574,13 @@ void NetworkContext::SetClient( +@@ -492,6 +570,13 @@ void NetworkContext::SetClient( client_.Bind(std::move(client)); } @@ -177,7 +177,7 @@ index 2c3f75ea4ad177a63d64081f5d8028b60771edb8..e62538f061cccddea14759ea5d92f14b std::unique_ptr network_delegate = std::make_unique( diff --git a/services/network/network_context.h b/services/network/network_context.h -index 5b26275cffb8155841498f22b994970e05997af2..0b35920f4dbaf8fbaf8245c9ae976459c6baa7b8 100644 +index 669fdf6d6c1ffb292a25b7ec608149f433312800..0bc906026e988819f66554749c8d6aa2f2accc49 100644 --- a/services/network/network_context.h +++ b/services/network/network_context.h @@ -86,6 +86,7 @@ class DomainReliabilityMonitor; @@ -188,7 +188,7 @@ index 5b26275cffb8155841498f22b994970e05997af2..0b35920f4dbaf8fbaf8245c9ae976459 class CookieManager; class ExpectCTReporter; class HostResolver; -@@ -189,6 +190,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext +@@ -182,6 +183,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext void CreateURLLoaderFactory( mojo::PendingReceiver receiver, mojom::URLLoaderFactoryParamsPtr params) override; @@ -197,7 +197,7 @@ index 5b26275cffb8155841498f22b994970e05997af2..0b35920f4dbaf8fbaf8245c9ae976459 void ResetURLLoaderFactories() override; void GetCookieManager( mojo::PendingReceiver receiver) override; -@@ -650,6 +653,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext +@@ -643,6 +646,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext std::unique_ptr nss_temp_certs_cache_; #endif @@ -207,7 +207,7 @@ index 5b26275cffb8155841498f22b994970e05997af2..0b35920f4dbaf8fbaf8245c9ae976459 // CertNetFetcher is not used by the current platform. scoped_refptr cert_net_fetcher_; diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom -index 4fc3dc0a66e975da82f8c5186378443569b01c13..2b2033797906f36fa829008c65e3b66b6e06eaa2 100644 +index 61c78d520becdb041f7b163bce5bb3fada44223a..248108042a5be07a3ddf6a11880ddbf04470d673 100644 --- a/services/network/public/mojom/network_context.mojom +++ b/services/network/public/mojom/network_context.mojom @@ -198,6 +198,17 @@ struct CTPolicy { @@ -228,7 +228,7 @@ index 4fc3dc0a66e975da82f8c5186378443569b01c13..2b2033797906f36fa829008c65e3b66b // Parameters for constructing a network context. struct NetworkContextParams { // Name used by memory tools to identify the context. -@@ -855,6 +866,9 @@ interface NetworkContext { +@@ -837,6 +848,9 @@ interface NetworkContext { // Sets a client for this network context. SetClient(pending_remote client); diff --git a/patches/chromium/notification_provenance.patch b/patches/chromium/notification_provenance.patch index 3f7224cd1df..a064e37aac4 100644 --- a/patches/chromium/notification_provenance.patch +++ b/patches/chromium/notification_provenance.patch @@ -68,10 +68,10 @@ index 619ad99bb52d489826d1e442a7719d985f0696ec..f7c9d3cac66879ce2be06a7a27ea96bf notification_service_remote_.BindNewPipeAndPassReceiver()); diff --git a/content/browser/notifications/platform_notification_context_impl.cc b/content/browser/notifications/platform_notification_context_impl.cc -index 2d76a71e57eade4f5fc01ff45a587ee9466baee0..62c0bb383813f07ef3a6d47988223f8c9e2788b0 100644 +index d221f2747086452c59474f17211adbfeec5a58b0..feee9f0b5f783cb4fbc60d3c29bddfaf5b4b6c46 100644 --- a/content/browser/notifications/platform_notification_context_impl.cc +++ b/content/browser/notifications/platform_notification_context_impl.cc -@@ -209,12 +209,13 @@ void PlatformNotificationContextImpl::Shutdown() { +@@ -208,12 +208,13 @@ void PlatformNotificationContextImpl::Shutdown() { } void PlatformNotificationContextImpl::CreateService( @@ -108,10 +108,10 @@ index 4bf25bf1fa69f7d3869369172d375e2e489e62a1..f80ef2cecc8b111dc54e109646573a59 mojo::PendingReceiver receiver); diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc -index 09252dcdf267aad57653a23def406653265eee13..64e781e055df605a2e205106eaed8264ebd3f4b8 100644 +index 49af7bd3719fe3c9848050f3f336bc02cfbfd2fb..f33eb6d5a0e98e06cd3ba318e9b578df4bc9ab2c 100644 --- a/content/browser/renderer_host/render_process_host_impl.cc +++ b/content/browser/renderer_host/render_process_host_impl.cc -@@ -2125,7 +2125,7 @@ void RenderProcessHostImpl::CreateNotificationService( +@@ -2120,7 +2120,7 @@ void RenderProcessHostImpl::CreateNotificationService( mojo::PendingReceiver receiver) { DCHECK_CURRENTLY_ON(BrowserThread::UI); storage_partition_impl_->GetPlatformNotificationContext()->CreateService( @@ -142,10 +142,10 @@ index ca61088079c4150fcf389504ddcf26bcf6bf69cd..d9c034c39890eef1fe3d95c6d7c0ae68 const GURL& origin, const blink::PlatformNotificationData& notification_data, diff --git a/content/test/mock_platform_notification_service.cc b/content/test/mock_platform_notification_service.cc -index 73a1af201b12bf818af2eafadad478b8c422826c..fc7e74c0bf900d475fc134a7b606c5f9e404f934 100644 +index 639a93ac8d4f295910fcfb64d69d1498c9dbbe94..25d7b29b53b426d02664bc904f1c646662d9a5d5 100644 --- a/content/test/mock_platform_notification_service.cc +++ b/content/test/mock_platform_notification_service.cc -@@ -31,6 +31,7 @@ MockPlatformNotificationService::MockPlatformNotificationService( +@@ -30,6 +30,7 @@ MockPlatformNotificationService::MockPlatformNotificationService( MockPlatformNotificationService::~MockPlatformNotificationService() = default; void MockPlatformNotificationService::DisplayNotification( diff --git a/patches/chromium/pepper_plugin_support.patch b/patches/chromium/pepper_plugin_support.patch index f3c0257bce5..4bfa1a224c2 100644 --- a/patches/chromium/pepper_plugin_support.patch +++ b/patches/chromium/pepper_plugin_support.patch @@ -35,13 +35,13 @@ index 2e328c0fb5a6598c3ae911655b3e5016a02b7405..304364f7e02c19d2ad7d16433e92dcfe // Permissions for the following interfaces will be checked at the // time of the corresponding instance's methods calls (because diff --git a/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc b/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc -index d72a867594acee97d50c5f905fc1a4df9aa9352e..8a4cc159cb490ebadbb1b54aa88223c0cbf8ffdb 100644 +index 82fa5b7026e62cfe69700f30fcc84731fc30afe8..f4ad9fbc72a5cb27ed22ab014ccb2fcb4cb49284 100644 --- a/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc +++ b/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc -@@ -7,10 +7,12 @@ +@@ -6,10 +6,12 @@ + #include - #include "base/task/post_task.h" +#if 0 #include "chrome/browser/content_settings/host_content_settings_map_factory.h" #include "chrome/browser/profiles/profile.h" @@ -51,7 +51,7 @@ index d72a867594acee97d50c5f905fc1a4df9aa9352e..8a4cc159cb490ebadbb1b54aa88223c0 #include "content/public/browser/browser_ppapi_host.h" #include "content/public/browser/browser_task_traits.h" #include "content/public/browser/browser_thread.h" -@@ -59,6 +61,7 @@ int32_t PepperBrokerMessageFilter::OnIsAllowed( +@@ -58,6 +60,7 @@ int32_t PepperBrokerMessageFilter::OnIsAllowed( RenderProcessHost::FromID(render_process_id_); if (!render_process_host) return PP_ERROR_FAILED; @@ -59,7 +59,7 @@ index d72a867594acee97d50c5f905fc1a4df9aa9352e..8a4cc159cb490ebadbb1b54aa88223c0 Profile* profile = Profile::FromBrowserContext(render_process_host->GetBrowserContext()); HostContentSettingsMap* content_settings = -@@ -68,5 +71,6 @@ int32_t PepperBrokerMessageFilter::OnIsAllowed( +@@ -67,5 +70,6 @@ int32_t PepperBrokerMessageFilter::OnIsAllowed( std::string()); if (setting == CONTENT_SETTING_ALLOW) return PP_OK; @@ -68,11 +68,11 @@ index d72a867594acee97d50c5f905fc1a4df9aa9352e..8a4cc159cb490ebadbb1b54aa88223c0 + return PP_OK; } diff --git a/chrome/browser/renderer_host/pepper/pepper_flash_browser_host.cc b/chrome/browser/renderer_host/pepper/pepper_flash_browser_host.cc -index c1fdd9dd86e4a205c6e2b51910f2bd2901501c75..77d65652808f2405881a8e1bb53d70d020866781 100644 +index 839b95e6a27e1296bae5e1bc98d5aedd7b2c3041..677b65e44440825d7fbba18f736ff970a8da3559 100644 --- a/chrome/browser/renderer_host/pepper/pepper_flash_browser_host.cc +++ b/chrome/browser/renderer_host/pepper/pepper_flash_browser_host.cc -@@ -8,9 +8,11 @@ - #include "base/task/post_task.h" +@@ -7,9 +7,11 @@ + #include "base/bind.h" #include "base/time/time.h" #include "build/build_config.h" +#if 0 @@ -83,7 +83,7 @@ index c1fdd9dd86e4a205c6e2b51910f2bd2901501c75..77d65652808f2405881a8e1bb53d70d0 #include "content/public/browser/browser_context.h" #include "content/public/browser/browser_ppapi_host.h" #include "content/public/browser/browser_task_traits.h" -@@ -41,6 +43,7 @@ using content::RenderProcessHost; +@@ -40,6 +42,7 @@ using content::RenderProcessHost; namespace { @@ -91,7 +91,7 @@ index c1fdd9dd86e4a205c6e2b51910f2bd2901501c75..77d65652808f2405881a8e1bb53d70d0 // Get the CookieSettings on the UI thread for the given render process ID. scoped_refptr GetCookieSettings( int render_process_id) { -@@ -54,6 +57,7 @@ scoped_refptr GetCookieSettings( +@@ -53,6 +56,7 @@ scoped_refptr GetCookieSettings( } return nullptr; } @@ -99,7 +99,7 @@ index c1fdd9dd86e4a205c6e2b51910f2bd2901501c75..77d65652808f2405881a8e1bb53d70d0 void BindWakeLockProviderOnUIThread( mojo::PendingReceiver receiver) { -@@ -67,7 +71,9 @@ PepperFlashBrowserHost::PepperFlashBrowserHost(BrowserPpapiHost* host, +@@ -66,7 +70,9 @@ PepperFlashBrowserHost::PepperFlashBrowserHost(BrowserPpapiHost* host, PP_Instance instance, PP_Resource resource) : ResourceHost(host->GetPpapiHost(), instance, resource), @@ -109,7 +109,7 @@ index c1fdd9dd86e4a205c6e2b51910f2bd2901501c75..77d65652808f2405881a8e1bb53d70d0 delay_timer_(FROM_HERE, base::TimeDelta::FromSeconds(45), this, -@@ -120,6 +126,7 @@ int32_t PepperFlashBrowserHost::OnGetLocalTimeZoneOffset( +@@ -119,6 +125,7 @@ int32_t PepperFlashBrowserHost::OnGetLocalTimeZoneOffset( int32_t PepperFlashBrowserHost::OnGetLocalDataRestrictions( ppapi::host::HostMessageContext* context) { @@ -117,7 +117,7 @@ index c1fdd9dd86e4a205c6e2b51910f2bd2901501c75..77d65652808f2405881a8e1bb53d70d0 // Getting the Flash LSO settings requires using the CookieSettings which // belong to the profile which lives on the UI thread. We lazily initialize // |cookie_settings_| by grabbing the reference from the UI thread and then -@@ -140,9 +147,11 @@ int32_t PepperFlashBrowserHost::OnGetLocalDataRestrictions( +@@ -138,9 +145,11 @@ int32_t PepperFlashBrowserHost::OnGetLocalDataRestrictions( context->MakeReplyMessageContext(), document_url, plugin_url)); } @@ -130,7 +130,7 @@ index c1fdd9dd86e4a205c6e2b51910f2bd2901501c75..77d65652808f2405881a8e1bb53d70d0 void PepperFlashBrowserHost::GetLocalDataRestrictions( ppapi::host::ReplyMessageContext reply_context, const GURL& document_url, -@@ -171,6 +180,7 @@ void PepperFlashBrowserHost::GetLocalDataRestrictions( +@@ -169,6 +178,7 @@ void PepperFlashBrowserHost::GetLocalDataRestrictions( PpapiPluginMsg_Flash_GetLocalDataRestrictionsReply( static_cast(restrictions))); } @@ -186,10 +186,10 @@ index 6b13bae8def62d9a26d68ac8396b4bf6f7439c1a..d92b5a5855c0cebf94922a31f686e15e DISALLOW_COPY_AND_ASSIGN(PepperFlashBrowserHost); diff --git a/chrome/browser/renderer_host/pepper/pepper_flash_drm_host.cc b/chrome/browser/renderer_host/pepper/pepper_flash_drm_host.cc -index 7c8c292d6d422139be89632dcb6a9d44106b3ac9..276d2fa32b25984e50eb5422e60a650fcb67fb71 100644 +index 7b774366e2ebd2405e0b85cdfbf1885c394afd0d..26996b7540d652ddb454cbb2fe3510d2a8aa31bf 100644 --- a/chrome/browser/renderer_host/pepper/pepper_flash_drm_host.cc +++ b/chrome/browser/renderer_host/pepper/pepper_flash_drm_host.cc -@@ -21,6 +21,7 @@ +@@ -20,6 +20,7 @@ #include "content/public/browser/child_process_security_policy.h" #include "content/public/browser/render_frame_host.h" #include "content/public/common/pepper_plugin_info.h" @@ -197,7 +197,7 @@ index 7c8c292d6d422139be89632dcb6a9d44106b3ac9..276d2fa32b25984e50eb5422e60a650f #include "ppapi/c/pp_errors.h" #include "ppapi/host/dispatch_host_message.h" #include "ppapi/host/host_message_context.h" -@@ -128,7 +129,9 @@ PepperFlashDRMHost::PepperFlashDRMHost(BrowserPpapiHost* host, +@@ -127,7 +128,9 @@ PepperFlashDRMHost::PepperFlashDRMHost(BrowserPpapiHost* host, content::ChildProcessSecurityPolicy::GetInstance()->GrantReadFile( render_process_id, voucher_file); @@ -207,7 +207,7 @@ index 7c8c292d6d422139be89632dcb6a9d44106b3ac9..276d2fa32b25984e50eb5422e60a650f monitor_finder_ = new MonitorFinder(render_process_id, render_frame_id); monitor_finder_->GetMonitor(); } -@@ -151,12 +154,18 @@ int32_t PepperFlashDRMHost::OnResourceMessageReceived( +@@ -150,12 +153,18 @@ int32_t PepperFlashDRMHost::OnResourceMessageReceived( int32_t PepperFlashDRMHost::OnHostMsgGetDeviceID( ppapi::host::HostMessageContext* context) { @@ -227,7 +227,7 @@ index 7c8c292d6d422139be89632dcb6a9d44106b3ac9..276d2fa32b25984e50eb5422e60a650f } int32_t PepperFlashDRMHost::OnHostMsgGetHmonitor( -@@ -185,6 +194,7 @@ int32_t PepperFlashDRMHost::OnHostMsgMonitorIsExternal( +@@ -184,6 +193,7 @@ int32_t PepperFlashDRMHost::OnHostMsgMonitorIsExternal( return PP_OK; } @@ -235,7 +235,7 @@ index 7c8c292d6d422139be89632dcb6a9d44106b3ac9..276d2fa32b25984e50eb5422e60a650f void PepperFlashDRMHost::GotDeviceID( ppapi::host::ReplyMessageContext reply_context, const std::string& id, -@@ -197,3 +207,4 @@ void PepperFlashDRMHost::GotDeviceID( +@@ -196,3 +206,4 @@ void PepperFlashDRMHost::GotDeviceID( host()->SendReply(reply_context, PpapiPluginMsg_FlashDRM_GetDeviceIDReply(id)); } @@ -265,13 +265,13 @@ index b9d2ce7f7f6837ee7b304daac82d21a3147c6faf..4d4b023d62d12b4d119acbfdee64f415 base::WeakPtrFactory weak_factory_{this}; diff --git a/chrome/browser/renderer_host/pepper/pepper_isolated_file_system_message_filter.cc b/chrome/browser/renderer_host/pepper/pepper_isolated_file_system_message_filter.cc -index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f99fd42e9e 100644 +index 0a04a1e0ec56126a7e44537141d024332b22a190..5384d7ac2f2eaf708bf001dd885f401783ac7133 100644 --- a/chrome/browser/renderer_host/pepper/pepper_isolated_file_system_message_filter.cc +++ b/chrome/browser/renderer_host/pepper/pepper_isolated_file_system_message_filter.cc -@@ -8,17 +8,21 @@ +@@ -7,17 +7,21 @@ + #include #include "base/stl_util.h" - #include "base/task/post_task.h" +#if 0 #include "chrome/browser/browser_process.h" #include "chrome/browser/profiles/profile.h" @@ -290,7 +290,7 @@ index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f9 #include "ppapi/c/pp_errors.h" #include "ppapi/host/dispatch_host_message.h" #include "ppapi/host/host_message_context.h" -@@ -27,12 +31,11 @@ +@@ -26,12 +30,11 @@ #include "ppapi/shared_impl/file_system_util.h" #include "storage/browser/file_system/isolated_context.h" @@ -304,7 +304,7 @@ index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f9 namespace { -@@ -42,6 +45,7 @@ const char* kPredefinedAllowedCrxFsOrigins[] = { +@@ -41,6 +44,7 @@ const char* kPredefinedAllowedCrxFsOrigins[] = { }; } // namespace @@ -312,7 +312,7 @@ index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f9 // static PepperIsolatedFileSystemMessageFilter* -@@ -69,8 +73,10 @@ PepperIsolatedFileSystemMessageFilter::PepperIsolatedFileSystemMessageFilter( +@@ -68,8 +72,10 @@ PepperIsolatedFileSystemMessageFilter::PepperIsolatedFileSystemMessageFilter( profile_directory_(profile_directory), document_url_(document_url), ppapi_host_(ppapi_host) { @@ -323,7 +323,7 @@ index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f9 } PepperIsolatedFileSystemMessageFilter:: -@@ -95,6 +101,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnResourceMessageReceived( +@@ -94,6 +100,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnResourceMessageReceived( return PP_ERROR_FAILED; } @@ -331,7 +331,7 @@ index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f9 Profile* PepperIsolatedFileSystemMessageFilter::GetProfile() { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); ProfileManager* profile_manager = g_browser_process->profile_manager(); -@@ -121,6 +128,7 @@ PepperIsolatedFileSystemMessageFilter::CreateCrxFileSystem(Profile* profile) { +@@ -120,6 +127,7 @@ PepperIsolatedFileSystemMessageFilter::CreateCrxFileSystem(Profile* profile) { return storage::IsolatedContext::ScopedFSHandle(); #endif } @@ -339,7 +339,7 @@ index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f9 int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem( ppapi::host::HostMessageContext* context, -@@ -129,7 +137,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem( +@@ -128,7 +136,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem( case PP_ISOLATEDFILESYSTEMTYPE_PRIVATE_INVALID: break; case PP_ISOLATEDFILESYSTEMTYPE_PRIVATE_CRX: @@ -348,7 +348,7 @@ index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f9 case PP_ISOLATEDFILESYSTEMTYPE_PRIVATE_PLUGINPRIVATE: return OpenPluginPrivateFileSystem(context); } -@@ -139,6 +147,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem( +@@ -138,6 +146,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem( return PP_ERROR_FAILED; } @@ -356,7 +356,7 @@ index c94e1947dc1b1ea83b27107c36e87c3dad5a61b1..b38862b776713958c54c3523b61a36f9 int32_t PepperIsolatedFileSystemMessageFilter::OpenCrxFileSystem( ppapi::host::HostMessageContext* context) { #if BUILDFLAG(ENABLE_EXTENSIONS) -@@ -179,6 +188,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OpenCrxFileSystem( +@@ -178,6 +187,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OpenCrxFileSystem( return PP_ERROR_NOTSUPPORTED; #endif } diff --git a/patches/chromium/picture-in-picture.patch b/patches/chromium/picture-in-picture.patch index fe90245efc1..8f984f28e29 100644 --- a/patches/chromium/picture-in-picture.patch +++ b/patches/chromium/picture-in-picture.patch @@ -35,7 +35,7 @@ index e9b64a823ae7e25361f37190d247af0fa6a6f68a..43fdb0ad50d2b11a1bc28aa0f358c6dd #include "ui/base/l10n/l10n_util.h" #include "ui/gfx/color_palette.h" diff --git a/chrome/browser/ui/views/overlay/overlay_window_views.cc b/chrome/browser/ui/views/overlay/overlay_window_views.cc -index 883958a432fc791824e2f94cf2bcba633ac74467..c90787bbbbcd49b278490362c72a9434deed4fb4 100644 +index 9b857313673a0233af1b20b72ecfeb52b2cff79d..3879843e937e134b74ea1a0a85a3ef5921a66eff 100644 --- a/chrome/browser/ui/views/overlay/overlay_window_views.cc +++ b/chrome/browser/ui/views/overlay/overlay_window_views.cc @@ -19,7 +19,7 @@ diff --git a/patches/chromium/preconnect_feature.patch b/patches/chromium/preconnect_feature.patch index f71db3d06b0..ba3c11a8acc 100644 --- a/patches/chromium/preconnect_feature.patch +++ b/patches/chromium/preconnect_feature.patch @@ -8,10 +8,10 @@ this patch removes that dependency so we can reuse it. Ideally we would change this class in upstream to not depend on Profile. diff --git a/chrome/browser/predictors/preconnect_manager.cc b/chrome/browser/predictors/preconnect_manager.cc -index 50adee35887f799fea11a35eca1240851a0d1126..9935e068983de3342382f73889be41acc3fe8f4e 100644 +index e6524169e022c98d07ca29fa7988c22b06f0a2e1..199837a907a8b9df0ef7d2cb9b369503ab655bf6 100644 --- a/chrome/browser/predictors/preconnect_manager.cc +++ b/chrome/browser/predictors/preconnect_manager.cc -@@ -69,7 +69,7 @@ PreresolveJob::PreresolveJob(PreresolveJob&& other) = default; +@@ -68,7 +68,7 @@ PreresolveJob::PreresolveJob(PreresolveJob&& other) = default; PreresolveJob::~PreresolveJob() = default; PreconnectManager::PreconnectManager(base::WeakPtr delegate, @@ -20,7 +20,7 @@ index 50adee35887f799fea11a35eca1240851a0d1126..9935e068983de3342382f73889be41ac : delegate_(std::move(delegate)), profile_(profile), inflight_preresolves_count_(0) { -@@ -328,11 +328,13 @@ network::mojom::NetworkContext* PreconnectManager::GetNetworkContext() const { +@@ -325,11 +325,13 @@ network::mojom::NetworkContext* PreconnectManager::GetNetworkContext() const { if (network_context_) return network_context_; diff --git a/patches/chromium/printing.patch b/patches/chromium/printing.patch index ff45c2c39d2..f8403d8ca25 100644 --- a/patches/chromium/printing.patch +++ b/patches/chromium/printing.patch @@ -10,38 +10,11 @@ majority of changes originally come from these PRs: This patch also fixes callback for manual user cancellation and success. -diff --git a/chrome/browser/printing/print_job.cc b/chrome/browser/printing/print_job.cc -index d23770fb402a1989027db54397fba80ceff9a296..61de329e09a08a9253eff554f6759fbef8214520 100644 ---- a/chrome/browser/printing/print_job.cc -+++ b/chrome/browser/printing/print_job.cc -@@ -57,7 +57,7 @@ enum class PrintRasterizationMode { - kMaxValue = kFast, - }; - --bool PrintWithReducedRasterization(PrefService* prefs) { -+ALLOW_UNUSED_TYPE bool PrintWithReducedRasterization(PrefService* prefs) { - // Managed preference takes precedence over user preference and field trials. - if (prefs->IsManagedPreference(prefs::kPrintRasterizationMode)) { - int value = prefs->GetInteger(prefs::kPrintRasterizationMode); -@@ -350,10 +350,13 @@ void PrintJob::StartPdfToEmfConversion( - settings.print_text_with_gdi() && !settings.printer_is_xps() && - base::FeatureList::IsEnabled(::features::kGdiTextPrinting); - -+ #if 0 - Profile* profile = Profile::FromBrowserContext( - worker_->GetWebContents()->GetBrowserContext()); - bool print_with_reduced_rasterization = - PrintWithReducedRasterization(profile->GetPrefs()); -+ #endif -+ bool print_with_reduced_rasterization = base::FeatureList::IsEnabled(features::kPrintWithReducedRasterization); - - using RenderMode = PdfRenderSettings::Mode; - RenderMode mode; diff --git a/chrome/browser/printing/print_job_worker.cc b/chrome/browser/printing/print_job_worker.cc -index 9122bbf4f15c46eefd5269946659b5886156348a..211ca535d4572f11de7256c108aa84a160169557 100644 +index 25fd623deb7a5d580d80dfa4d99d4628c6800eb3..dd76a610f05e636a6f01e4f21a11507f65867a15 100644 --- a/chrome/browser/printing/print_job_worker.cc +++ b/chrome/browser/printing/print_job_worker.cc -@@ -21,7 +21,6 @@ +@@ -20,7 +20,6 @@ #include "chrome/browser/browser_process.h" #include "chrome/browser/chrome_notification_types.h" #include "chrome/browser/printing/print_job.h" @@ -49,7 +22,7 @@ index 9122bbf4f15c46eefd5269946659b5886156348a..211ca535d4572f11de7256c108aa84a1 #include "components/crash/core/common/crash_keys.h" #include "content/public/browser/browser_task_traits.h" #include "content/public/browser/browser_thread.h" -@@ -29,6 +28,7 @@ +@@ -28,6 +27,7 @@ #include "content/public/browser/render_frame_host.h" #include "content/public/browser/web_contents.h" #include "printing/backend/print_backend.h" @@ -57,7 +30,7 @@ index 9122bbf4f15c46eefd5269946659b5886156348a..211ca535d4572f11de7256c108aa84a1 #include "printing/print_job_constants.h" #include "printing/printed_document.h" #include "printing/printing_utils.h" -@@ -224,16 +224,21 @@ void PrintJobWorker::UpdatePrintSettings(base::Value new_settings, +@@ -223,16 +223,21 @@ void PrintJobWorker::UpdatePrintSettings(base::Value new_settings, print_backend->GetPrinterDriverInfo(printer_name)); } @@ -82,7 +55,7 @@ index 9122bbf4f15c46eefd5269946659b5886156348a..211ca535d4572f11de7256c108aa84a1 } #if defined(OS_CHROMEOS) -@@ -249,6 +254,13 @@ void PrintJobWorker::UpdatePrintSettingsFromPOD( +@@ -248,6 +253,13 @@ void PrintJobWorker::UpdatePrintSettingsFromPOD( void PrintJobWorker::GetSettingsDone(SettingsCallback callback, PrintingContext::Result result) { @@ -97,10 +70,10 @@ index 9122bbf4f15c46eefd5269946659b5886156348a..211ca535d4572f11de7256c108aa84a1 } diff --git a/chrome/browser/printing/print_view_manager_base.cc b/chrome/browser/printing/print_view_manager_base.cc -index 5531a6e8cbc83cff104f70d4da3576f5af03209c..0d70e8132669aae179738086a7989bd60c0c28ee 100644 +index 8a743d0dd74b087059ff812019ae568a22c5fa01..20c43be03706617a276d210190897dc473bbd0da 100644 --- a/chrome/browser/printing/print_view_manager_base.cc +++ b/chrome/browser/printing/print_view_manager_base.cc -@@ -28,10 +28,7 @@ +@@ -27,10 +27,7 @@ #include "chrome/browser/printing/print_view_manager_common.h" #include "chrome/browser/printing/printer_query.h" #include "chrome/browser/profiles/profile.h" @@ -315,10 +288,10 @@ index 94b65e85561e1440b60086b668865bda07303d35..7044463d163fd74e55ff1a042c36739f // This means we are _blocking_ until all the necessary pages have been // rendered or the print settings are being loaded. diff --git a/chrome/browser/printing/printing_message_filter.cc b/chrome/browser/printing/printing_message_filter.cc -index 86ee19d5926df13cea1c8bb9bbe223061b8d7a79..7177042770391880b235a1e25ec75567229d3115 100644 +index f4094c54075b9d4cdcbf1aa78c7264882889c76e..1643c637cf0b05427b9dd72e60045a60952ca04f 100644 --- a/chrome/browser/printing/printing_message_filter.cc +++ b/chrome/browser/printing/printing_message_filter.cc -@@ -22,6 +22,7 @@ +@@ -21,6 +21,7 @@ #include "components/keyed_service/content/browser_context_keyed_service_shutdown_notifier_factory.h" #include "components/printing/browser/print_manager_utils.h" #include "components/printing/common/print_messages.h" @@ -326,7 +299,7 @@ index 86ee19d5926df13cea1c8bb9bbe223061b8d7a79..7177042770391880b235a1e25ec75567 #include "content/public/browser/browser_task_traits.h" #include "content/public/browser/render_frame_host.h" #include "content/public/browser/web_contents.h" -@@ -90,20 +91,23 @@ void PrintingMessageFilter::SetDelegateForTesting(TestDelegate* delegate) { +@@ -89,19 +90,22 @@ void PrintingMessageFilter::SetDelegateForTesting(TestDelegate* delegate) { g_test_delegate = delegate; } @@ -347,13 +320,12 @@ index 86ee19d5926df13cea1c8bb9bbe223061b8d7a79..7177042770391880b235a1e25ec75567 base::Unretained(this))); + #if 0 is_printing_enabled_.Init(prefs::kPrintingEnabled, profile->GetPrefs()); - is_printing_enabled_.MoveToSequence( - base::CreateSingleThreadTaskRunner({BrowserThread::IO})); + is_printing_enabled_.MoveToSequence(content::GetIOThreadTaskRunner({})); + #endif } PrintingMessageFilter::~PrintingMessageFilter() { -@@ -135,11 +139,13 @@ bool PrintingMessageFilter::OnMessageReceived(const IPC::Message& message) { +@@ -133,11 +137,13 @@ bool PrintingMessageFilter::OnMessageReceived(const IPC::Message& message) { void PrintingMessageFilter::OnGetDefaultPrintSettings(IPC::Message* reply_msg) { DCHECK_CURRENTLY_ON(BrowserThread::IO); @@ -367,7 +339,7 @@ index 86ee19d5926df13cea1c8bb9bbe223061b8d7a79..7177042770391880b235a1e25ec75567 std::unique_ptr printer_query = queue_->PopPrinterQuery(0); if (!printer_query) { printer_query = -@@ -225,12 +231,13 @@ void PrintingMessageFilter::OnScriptedPrintReply( +@@ -223,12 +229,13 @@ void PrintingMessageFilter::OnScriptedPrintReply( void PrintingMessageFilter::OnUpdatePrintSettings(int document_cookie, base::Value job_settings, IPC::Message* reply_msg) { @@ -382,7 +354,7 @@ index 86ee19d5926df13cea1c8bb9bbe223061b8d7a79..7177042770391880b235a1e25ec75567 if (!job_settings.is_dict() || !job_settings.FindIntKey(kSettingPrinterType)) { // Reply with null query. -@@ -263,7 +270,9 @@ void PrintingMessageFilter::OnUpdatePrintSettingsReply( +@@ -261,7 +268,9 @@ void PrintingMessageFilter::OnUpdatePrintSettingsReply( std::unique_ptr printer_query, IPC::Message* reply_msg) { PrintMsg_PrintPages_Params params; @@ -419,10 +391,10 @@ index 49296adb525eeb511d4aad5f25ff1196f9f1333e..2d705bb98f47e79f0922af9675c42800 // content::BrowserMessageFilter: bool OnMessageReceived(const IPC::Message& message) override; diff --git a/components/printing/common/print.mojom b/components/printing/common/print.mojom -index 912652847ab45c811400dbee81bc5161d5865c56..5fb26c8952117c5110707b1c6b45158090b37ded 100644 +index 5398362ff64fe948b492aa6dd362f2aa6ab19231..3ff75b7850e8ebb03cc202a2cc3f70fba0b1174f 100644 --- a/components/printing/common/print.mojom +++ b/components/printing/common/print.mojom -@@ -93,7 +93,7 @@ interface PrintPreviewUI { +@@ -104,7 +104,7 @@ interface PrintPreviewUI { interface PrintRenderFrame { // Tells the RenderFrame to switch the CSS to print media type, render every // requested page, and then switch back the CSS to display media type. @@ -432,7 +404,7 @@ index 912652847ab45c811400dbee81bc5161d5865c56..5fb26c8952117c5110707b1c6b451580 // Tells the RenderFrame to switch the CSS to print media type, render every // requested page using the print preview document's frame/node, and then diff --git a/components/printing/renderer/print_render_frame_helper.cc b/components/printing/renderer/print_render_frame_helper.cc -index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada7023dad1 100644 +index a5aa97ab6254c27d04beaf758fbf9916189e3284..e566b1d22a5bb0aa40f15db83f1dc89e9099f62c 100644 --- a/components/printing/renderer/print_render_frame_helper.cc +++ b/components/printing/renderer/print_render_frame_helper.cc @@ -44,6 +44,7 @@ @@ -443,7 +415,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada #include "printing/units.h" #include "third_party/blink/public/common/associated_interfaces/associated_interface_registry.h" #include "third_party/blink/public/common/css/page_orientation.h" -@@ -1174,7 +1175,8 @@ void PrintRenderFrameHelper::ScriptedPrint(bool user_initiated) { +@@ -1173,7 +1174,8 @@ void PrintRenderFrameHelper::ScriptedPrint(bool user_initiated) { web_frame->DispatchBeforePrintEvent(); if (!weak_this) return; @@ -453,7 +425,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada if (weak_this) web_frame->DispatchAfterPrintEvent(); } -@@ -1195,7 +1197,7 @@ void PrintRenderFrameHelper::BindPrintRenderFrameReceiver( +@@ -1194,7 +1196,7 @@ void PrintRenderFrameHelper::BindPrintRenderFrameReceiver( receivers_.Add(this, std::move(receiver)); } @@ -462,7 +434,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada ScopedIPC scoped_ipc(weak_ptr_factory_.GetWeakPtr()); if (ipc_nesting_level_ > 1) return; -@@ -1209,7 +1211,7 @@ void PrintRenderFrameHelper::PrintRequestedPages() { +@@ -1208,7 +1210,7 @@ void PrintRenderFrameHelper::PrintRequestedPages() { // If we are printing a PDF extension frame, find the plugin node and print // that instead. auto plugin = delegate_->GetPdfElement(frame); @@ -471,7 +443,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada if (!render_frame_gone_) frame->DispatchAfterPrintEvent(); // WARNING: |this| may be gone at this point. Do not do any more work here and -@@ -1226,7 +1228,7 @@ void PrintRenderFrameHelper::PrintForSystemDialog() { +@@ -1225,7 +1227,7 @@ void PrintRenderFrameHelper::PrintForSystemDialog() { return; } Print(frame, print_preview_context_.source_node(), @@ -480,7 +452,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada if (!render_frame_gone_) frame->DispatchAfterPrintEvent(); // WARNING: |this| may be gone at this point. Do not do any more work here and -@@ -1274,6 +1276,8 @@ void PrintRenderFrameHelper::PrintPreview(base::Value settings) { +@@ -1273,6 +1275,8 @@ void PrintRenderFrameHelper::PrintPreview(base::Value settings) { if (ipc_nesting_level_ > 1) return; @@ -489,7 +461,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada print_preview_context_.OnPrintPreview(); base::UmaHistogramEnumeration(print_preview_context_.IsForArc() -@@ -1785,7 +1789,9 @@ void PrintRenderFrameHelper::PrintNode(const blink::WebNode& node) { +@@ -1784,7 +1788,9 @@ void PrintRenderFrameHelper::PrintNode(const blink::WebNode& node) { auto self = weak_ptr_factory_.GetWeakPtr(); Print(duplicate_node.GetDocument().GetFrame(), duplicate_node, @@ -500,7 +472,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada // Check if |this| is still valid. if (!self) return; -@@ -1796,7 +1802,9 @@ void PrintRenderFrameHelper::PrintNode(const blink::WebNode& node) { +@@ -1795,7 +1801,9 @@ void PrintRenderFrameHelper::PrintNode(const blink::WebNode& node) { void PrintRenderFrameHelper::Print(blink::WebLocalFrame* frame, const blink::WebNode& node, @@ -511,7 +483,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada // If still not finished with earlier print request simply ignore. if (prep_frame_view_) return; -@@ -1804,7 +1812,7 @@ void PrintRenderFrameHelper::Print(blink::WebLocalFrame* frame, +@@ -1803,7 +1811,7 @@ void PrintRenderFrameHelper::Print(blink::WebLocalFrame* frame, FrameReference frame_ref(frame); int expected_page_count = 0; @@ -520,7 +492,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada DidFinishPrinting(FAIL_PRINT_INIT); return; // Failed to init print page settings. } -@@ -1824,8 +1832,11 @@ void PrintRenderFrameHelper::Print(blink::WebLocalFrame* frame, +@@ -1823,8 +1831,11 @@ void PrintRenderFrameHelper::Print(blink::WebLocalFrame* frame, PrintMsg_PrintPages_Params print_settings; auto self = weak_ptr_factory_.GetWeakPtr(); @@ -534,7 +506,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada // Check if |this| is still valid. if (!self) return; -@@ -2061,10 +2072,23 @@ void PrintRenderFrameHelper::IPCProcessed() { +@@ -2060,10 +2071,23 @@ void PrintRenderFrameHelper::IPCProcessed() { base::ThreadTaskRunnerHandle::Get()->DeleteSoon(FROM_HERE, this); } @@ -561,7 +533,7 @@ index ccd164ad24e4c401be746c0ac9716d1d259c0a85..1db0c6cad6cc27b3a548b78d701d2ada // Check if the printer returned any settings, if the settings is empty, we // can safely assume there are no printer drivers configured. So we safely // terminate. -@@ -2084,12 +2108,14 @@ bool PrintRenderFrameHelper::InitPrintSettings(bool fit_to_paper_size) { +@@ -2083,12 +2107,14 @@ bool PrintRenderFrameHelper::InitPrintSettings(bool fit_to_paper_size) { return result; } diff --git a/patches/chromium/refactor_expose_cursor_changes_to_the_webcontentsobserver.patch b/patches/chromium/refactor_expose_cursor_changes_to_the_webcontentsobserver.patch index 5f18d45afbe..7e3923110f5 100644 --- a/patches/chromium/refactor_expose_cursor_changes_to_the_webcontentsobserver.patch +++ b/patches/chromium/refactor_expose_cursor_changes_to_the_webcontentsobserver.patch @@ -8,7 +8,7 @@ Chrome moved the SetCursor IPC message to mojo, which we use to tell OSR about ` Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2172779 diff --git a/content/browser/renderer_host/render_widget_host_delegate.h b/content/browser/renderer_host/render_widget_host_delegate.h -index 2edad62668474c690adb283224400dc4e7163fbf..1c7928e66955e188f70d4f1c475f2ad33db80cb0 100644 +index 7e9bddc9f002b938ed7804af7c484f4500988a9e..f77130c39b853ed6ba30e62dd59c4afec93d8d31 100644 --- a/content/browser/renderer_host/render_widget_host_delegate.h +++ b/content/browser/renderer_host/render_widget_host_delegate.h @@ -15,6 +15,7 @@ @@ -30,10 +30,10 @@ index 2edad62668474c690adb283224400dc4e7163fbf..1c7928e66955e188f70d4f1c475f2ad3 // RenderWidgetHost on the main frame, and false otherwise. virtual bool IsWidgetForMainFrame(RenderWidgetHostImpl*); diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc -index 77526d78e8113f7071fe269cbcdf63bb772db6e4..933377708dd4ef1793863fb042fd74c0aaef3f4c 100644 +index e660c0e072a6fa855102ec7e4d8a883a923e46ae..856f72a6c0fe0f55ff33cedcd6c777f17b7e7231 100644 --- a/content/browser/renderer_host/render_widget_host_impl.cc +++ b/content/browser/renderer_host/render_widget_host_impl.cc -@@ -1599,6 +1599,8 @@ void RenderWidgetHostImpl::SetCursor(const WebCursor& cursor) { +@@ -1646,6 +1646,8 @@ void RenderWidgetHostImpl::SetCursor(const WebCursor& cursor) { if (!view_) return; view_->UpdateCursor(cursor); @@ -43,10 +43,10 @@ index 77526d78e8113f7071fe269cbcdf63bb772db6e4..933377708dd4ef1793863fb042fd74c0 void RenderWidgetHostImpl::OnCursorVisibilityStateChanged(bool is_visible) { diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc -index 402450783e76fedd1264d6d7f47352dd233be621..bf744d187a84df4c3ea93ec16ef2cc1ef5013d92 100644 +index 9def30b2994eddef546509f90b6beba0da5815f1..004045e3223bf89d7e71f3dee5e221dbd1dc06cd 100644 --- a/content/browser/web_contents/web_contents_impl.cc +++ b/content/browser/web_contents/web_contents_impl.cc -@@ -3454,6 +3454,11 @@ bool WebContentsImpl::OnUpdateDragCursor() { +@@ -3468,6 +3468,11 @@ bool WebContentsImpl::OnUpdateDragCursor() { browser_plugin_embedder_->OnUpdateDragCursor(); } @@ -59,7 +59,7 @@ index 402450783e76fedd1264d6d7f47352dd233be621..bf744d187a84df4c3ea93ec16ef2cc1e RenderWidgetHostImpl* render_widget_host) { return render_widget_host == GetMainFrame()->GetRenderWidgetHost(); diff --git a/content/browser/web_contents/web_contents_impl.h b/content/browser/web_contents/web_contents_impl.h -index 71ddac828df2e3df42214aee30d8b0fa866938fe..acae46fdac0d8dc2a26c72595b6e4b49dc21106a 100644 +index 3316e61f8c1c1295748d5fc279fc3f14140fc59d..2558f46121c3635a54b22dde070def374d511bb3 100644 --- a/content/browser/web_contents/web_contents_impl.h +++ b/content/browser/web_contents/web_contents_impl.h @@ -912,6 +912,7 @@ class CONTENT_EXPORT WebContentsImpl : public WebContents, @@ -71,7 +71,7 @@ index 71ddac828df2e3df42214aee30d8b0fa866938fe..acae46fdac0d8dc2a26c72595b6e4b49 bool AddDomainInfoToRapporSample(rappor::Sample* sample) override; bool IsShowingContextMenuOnPage() const override; diff --git a/content/public/browser/web_contents_observer.h b/content/public/browser/web_contents_observer.h -index d84c9abf8e8e46606a23d5e66ce740afeac01179..111d867f8a9076cf32e09d357dce9ff9aa1cadc2 100644 +index da2c6572dd7e9bbd6f59b864edc73dae56ca2103..4eb46a9b37f66fe41ae9e62ac8848801e065acda 100644 --- a/content/public/browser/web_contents_observer.h +++ b/content/public/browser/web_contents_observer.h @@ -14,6 +14,7 @@ @@ -82,7 +82,7 @@ index d84c9abf8e8e46606a23d5e66ce740afeac01179..111d867f8a9076cf32e09d357dce9ff9 #include "content/public/browser/allow_service_worker_result.h" #include "content/public/browser/cookie_access_details.h" #include "content/public/browser/navigation_controller.h" -@@ -354,6 +355,9 @@ class CONTENT_EXPORT WebContentsObserver : public IPC::Listener { +@@ -365,6 +366,9 @@ class CONTENT_EXPORT WebContentsObserver : public IPC::Listener { // Invoked every time the WebContents changes visibility. virtual void OnVisibilityChanged(Visibility visibility) {} diff --git a/patches/chromium/render_widget_host_view_base.patch b/patches/chromium/render_widget_host_view_base.patch index 2ef9f307438..7529d6b85a5 100644 --- a/patches/chromium/render_widget_host_view_base.patch +++ b/patches/chromium/render_widget_host_view_base.patch @@ -6,10 +6,10 @@ Subject: render_widget_host_view_base.patch ... something to do with OSR? and maybe as well? terrifying. diff --git a/content/browser/renderer_host/render_widget_host_view_base.cc b/content/browser/renderer_host/render_widget_host_view_base.cc -index 403a8c870a59d9dd46d20aa51b5bf966d47ed162..5914d502c879d32023a2659fac754aa925752145 100644 +index 2a5c601db29a774abb1ca8805500844a75806c8a..30668e00754990228560c5addb9ae4b9e43e33a9 100644 --- a/content/browser/renderer_host/render_widget_host_view_base.cc +++ b/content/browser/renderer_host/render_widget_host_view_base.cc -@@ -608,6 +608,13 @@ bool RenderWidgetHostViewBase::ScreenRectIsUnstableFor( +@@ -617,6 +617,13 @@ bool RenderWidgetHostViewBase::ScreenRectIsUnstableFor( return false; } @@ -24,12 +24,12 @@ index 403a8c870a59d9dd46d20aa51b5bf966d47ed162..5914d502c879d32023a2659fac754aa9 const blink::WebMouseEvent& event, const ui::LatencyInfo& latency) { diff --git a/content/browser/renderer_host/render_widget_host_view_base.h b/content/browser/renderer_host/render_widget_host_view_base.h -index 39f1c8d6ee464ba577d483308e73bc028c901d27..880ddb6b20c3ef19a537fd96511a096a7d29c606 100644 +index d224ea8b2c6be728639336949de0221fe381be48..09513e385d46d2a57c54bd437893eb5a72bebc1b 100644 --- a/content/browser/renderer_host/render_widget_host_view_base.h +++ b/content/browser/renderer_host/render_widget_host_view_base.h -@@ -23,9 +23,11 @@ - #include "components/viz/common/surfaces/surface_id.h" +@@ -24,9 +24,11 @@ #include "components/viz/host/hit_test/hit_test_query.h" + #include "content/browser/renderer_host/display_feature.h" #include "content/browser/renderer_host/event_with_latency_info.h" +#include "content/browser/web_contents/web_contents_view.h" #include "content/common/content_export.h" @@ -39,7 +39,7 @@ index 39f1c8d6ee464ba577d483308e73bc028c901d27..880ddb6b20c3ef19a537fd96511a096a #include "content/public/browser/render_widget_host_view.h" #include "content/public/common/screen_info.h" #include "content/public/common/widget_type.h" -@@ -65,9 +67,11 @@ class CursorManager; +@@ -66,9 +68,11 @@ class CursorManager; class MouseWheelPhaseHandler; class RenderWidgetHostImpl; class RenderWidgetHostViewBaseObserver; @@ -50,8 +50,8 @@ index 39f1c8d6ee464ba577d483308e73bc028c901d27..880ddb6b20c3ef19a537fd96511a096a +class WebContentsView; class WebCursor; class DelegatedFrameHost; - struct TextInputState; -@@ -126,6 +130,9 @@ class CONTENT_EXPORT RenderWidgetHostViewBase + struct DisplayFeature; +@@ -128,6 +132,9 @@ class CONTENT_EXPORT RenderWidgetHostViewBase bool show_reason_unoccluded, bool show_reason_bfcache_restore) final; @@ -61,7 +61,7 @@ index 39f1c8d6ee464ba577d483308e73bc028c901d27..880ddb6b20c3ef19a537fd96511a096a // This only needs to be overridden by RenderWidgetHostViewBase subclasses // that handle content embedded within other RenderWidgetHostViews. gfx::PointF TransformPointToRootCoordSpaceF( -@@ -310,6 +317,11 @@ class CONTENT_EXPORT RenderWidgetHostViewBase +@@ -312,6 +319,11 @@ class CONTENT_EXPORT RenderWidgetHostViewBase virtual void ProcessGestureEvent(const blink::WebGestureEvent& event, const ui::LatencyInfo& latency); diff --git a/patches/chromium/revert_remove_contentrendererclient_shouldfork.patch b/patches/chromium/revert_remove_contentrendererclient_shouldfork.patch index 171850d9c5d..20dc20c65c7 100644 --- a/patches/chromium/revert_remove_contentrendererclient_shouldfork.patch +++ b/patches/chromium/revert_remove_contentrendererclient_shouldfork.patch @@ -74,10 +74,10 @@ index ea6d8e6357233f519c3cf41a96d8453993a9ce71..c513aff3e1c3da45e45954bc0beb8046 blink::WebLocalFrame* frame, ui::PageTransition transition_type, diff --git a/content/public/renderer/content_renderer_client.h b/content/public/renderer/content_renderer_client.h -index de0274d03ff1a0838f0ab0002c5a6b6ea7e10bfd..892366cd9d2f70498e2e7429a66dcf135d79bb27 100644 +index 9d321040de33acac09e83cc582f685740f425009..8f328979cc232c4f81a7f040e2424273a8248015 100644 --- a/content/public/renderer/content_renderer_client.h +++ b/content/public/renderer/content_renderer_client.h -@@ -227,6 +227,13 @@ class CONTENT_EXPORT ContentRendererClient { +@@ -228,6 +228,13 @@ class CONTENT_EXPORT ContentRendererClient { bool is_redirect); #endif @@ -92,10 +92,10 @@ index de0274d03ff1a0838f0ab0002c5a6b6ea7e10bfd..892366cd9d2f70498e2e7429a66dcf13 // |url|. If the function returns a valid |new_url|, the request must be // updated to use it. The |force_ignore_site_for_cookies| output parameter diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc -index 95cec369e38dada721cbf26fe244461171d748f8..e9d835953e19488a4477051fc34c8e489f333c91 100644 +index cb612a7002a4ae808ca488e2aa2adbb759310964..6442139eba458788125c7dbb03d1af6a8c156255 100644 --- a/content/renderer/render_frame_impl.cc +++ b/content/renderer/render_frame_impl.cc -@@ -5575,6 +5575,23 @@ void RenderFrameImpl::BeginNavigation( +@@ -5502,6 +5502,23 @@ void RenderFrameImpl::BeginNavigation( // we can do a per-frame check here rather than a process-wide check. bool should_fork = HasWebUIScheme(url) || HasWebUIScheme(old_url) || (enabled_bindings_ & kWebUIBindingsPolicyMask); diff --git a/patches/chromium/scroll_bounce_flag.patch b/patches/chromium/scroll_bounce_flag.patch index f56a5ac4464..3975d12df27 100644 --- a/patches/chromium/scroll_bounce_flag.patch +++ b/patches/chromium/scroll_bounce_flag.patch @@ -6,10 +6,10 @@ Subject: scroll_bounce_flag.patch Patch to make scrollBounce option work. diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc -index 071f1a0b5994c6709b5b0e39f4ed33c90f282c39..0257f74577641adca495473aa0ca0224602e107e 100644 +index 1c01ee6dda5857559b089022d4fdde5b33273745..9b311fe4c118db35a9008a9ad153a52a71625771 100644 --- a/content/renderer/render_thread_impl.cc +++ b/content/renderer/render_thread_impl.cc -@@ -1350,7 +1350,7 @@ bool RenderThreadImpl::IsGpuMemoryBufferCompositorResourcesEnabled() { +@@ -1355,7 +1355,7 @@ bool RenderThreadImpl::IsGpuMemoryBufferCompositorResourcesEnabled() { } bool RenderThreadImpl::IsElasticOverscrollEnabled() { diff --git a/patches/chromium/support_mixed_sandbox_with_zygote.patch b/patches/chromium/support_mixed_sandbox_with_zygote.patch index 5ad707cb873..6a144546189 100644 --- a/patches/chromium/support_mixed_sandbox_with_zygote.patch +++ b/patches/chromium/support_mixed_sandbox_with_zygote.patch @@ -22,10 +22,10 @@ However, the patch would need to be reviewed by the security team, as it does touch a security-sensitive class. diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc -index 64e781e055df605a2e205106eaed8264ebd3f4b8..11b18f08dbaba89a483908faef465adfb6bd4019 100644 +index f33eb6d5a0e98e06cd3ba318e9b578df4bc9ab2c..0e84525e677131b3428e5fe73dfb7b48bf65a692 100644 --- a/content/browser/renderer_host/render_process_host_impl.cc +++ b/content/browser/renderer_host/render_process_host_impl.cc -@@ -416,6 +416,11 @@ class RendererSandboxedProcessLauncherDelegate +@@ -412,6 +412,11 @@ class RendererSandboxedProcessLauncherDelegate { } @@ -37,7 +37,7 @@ index 64e781e055df605a2e205106eaed8264ebd3f4b8..11b18f08dbaba89a483908faef465adf ~RendererSandboxedProcessLauncherDelegate() override {} #if defined(OS_WIN) -@@ -437,6 +442,9 @@ class RendererSandboxedProcessLauncherDelegate +@@ -433,6 +438,9 @@ class RendererSandboxedProcessLauncherDelegate #if BUILDFLAG(USE_ZYGOTE_HANDLE) service_manager::ZygoteHandle GetZygote() override { @@ -47,7 +47,7 @@ index 64e781e055df605a2e205106eaed8264ebd3f4b8..11b18f08dbaba89a483908faef465adf const base::CommandLine& browser_command_line = *base::CommandLine::ForCurrentProcess(); base::CommandLine::StringType renderer_prefix = -@@ -451,10 +459,13 @@ class RendererSandboxedProcessLauncherDelegate +@@ -447,10 +455,13 @@ class RendererSandboxedProcessLauncherDelegate return service_manager::SandboxType::kRenderer; } @@ -62,7 +62,7 @@ index 64e781e055df605a2e205106eaed8264ebd3f4b8..11b18f08dbaba89a483908faef465adf }; const char kSessionStorageHolderKey[] = "kSessionStorageHolderKey"; -@@ -1836,11 +1847,18 @@ bool RenderProcessHostImpl::Init() { +@@ -1831,11 +1842,18 @@ bool RenderProcessHostImpl::Init() { cmd_line->PrependWrapper(renderer_prefix); AppendRendererCommandLine(cmd_line.get()); diff --git a/patches/chromium/unsandboxed_ppapi_processes_skip_zygote.patch b/patches/chromium/unsandboxed_ppapi_processes_skip_zygote.patch index 1e68ef6cf1e..6028d3b1045 100644 --- a/patches/chromium/unsandboxed_ppapi_processes_skip_zygote.patch +++ b/patches/chromium/unsandboxed_ppapi_processes_skip_zygote.patch @@ -6,7 +6,7 @@ Subject: unsandboxed_ppapi_processes_skip_zygote.patch Unsandboxed ppapi processes should skip zygote. diff --git a/content/browser/ppapi_plugin_process_host.cc b/content/browser/ppapi_plugin_process_host.cc -index 0fa99dc66e837110595d993114bb12b93ebf8a2d..ff5eeec244933de21afa8f97c574c1c4988d83f1 100644 +index 18ca6cf2de5b58f65a4786f9b7bfcd8ad0c2e9ae..0792c6f681f2cec8993de8c51fabdc5bc102ed25 100644 --- a/content/browser/ppapi_plugin_process_host.cc +++ b/content/browser/ppapi_plugin_process_host.cc @@ -123,6 +123,9 @@ class PpapiPluginSandboxedProcessLauncherDelegate diff --git a/patches/chromium/web_contents.patch b/patches/chromium/web_contents.patch index bc19c071b0c..10e1f0c94a8 100644 --- a/patches/chromium/web_contents.patch +++ b/patches/chromium/web_contents.patch @@ -9,10 +9,10 @@ is needed for OSR. Originally landed in https://github.com/electron/libchromiumcontent/pull/226. diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc -index 31b30a3f729258accab5a135eeddba7b79990e81..402450783e76fedd1264d6d7f47352dd233be621 100644 +index 725e9f890bf5479d4435b9e7366b8fe2a10e0919..9def30b2994eddef546509f90b6beba0da5815f1 100644 --- a/content/browser/web_contents/web_contents_impl.cc +++ b/content/browser/web_contents/web_contents_impl.cc -@@ -2100,6 +2100,12 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) { +@@ -2117,6 +2117,12 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) { std::string unique_name; frame_tree_.root()->SetFrameName(params.main_frame_name, unique_name); @@ -25,7 +25,7 @@ index 31b30a3f729258accab5a135eeddba7b79990e81..402450783e76fedd1264d6d7f47352dd WebContentsViewDelegate* delegate = GetContentClient()->browser()->GetWebContentsViewDelegate(this); -@@ -2110,6 +2116,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) { +@@ -2127,6 +2133,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) { view_.reset(CreateWebContentsView(this, delegate, &render_view_host_delegate_view_)); } diff --git a/patches/chromium/webview_cross_drag.patch b/patches/chromium/webview_cross_drag.patch index 92693e15dad..4afdf292524 100644 --- a/patches/chromium/webview_cross_drag.patch +++ b/patches/chromium/webview_cross_drag.patch @@ -8,10 +8,10 @@ This allows dragging and dropping between s. Originally landed in https://github.com/electron/libchromiumcontent/pull/267 diff --git a/content/browser/web_contents/web_contents_view_aura.cc b/content/browser/web_contents/web_contents_view_aura.cc -index b5dd9b3023750cb6b23627788b411832cf53f702..baaf3383a55e897483829c79a297e06b3210ea29 100644 +index 3b77ea4ae732825a8fc85f1547b428ebc6d90a6e..692ee207db0389aab2de854ac3b6adc3f206961e 100644 --- a/content/browser/web_contents/web_contents_view_aura.cc +++ b/content/browser/web_contents/web_contents_view_aura.cc -@@ -784,9 +784,7 @@ gfx::NativeView WebContentsViewAura::GetRenderWidgetHostViewParent() const { +@@ -785,9 +785,7 @@ gfx::NativeView WebContentsViewAura::GetRenderWidgetHostViewParent() const { bool WebContentsViewAura::IsValidDragTarget( RenderWidgetHostImpl* target_rwh) const { diff --git a/patches/chromium/worker_context_will_destroy.patch b/patches/chromium/worker_context_will_destroy.patch index f179b7eb836..fd072c2f70f 100644 --- a/patches/chromium/worker_context_will_destroy.patch +++ b/patches/chromium/worker_context_will_destroy.patch @@ -10,10 +10,10 @@ An attempt to upstream this was made, but rejected: https://chromium-review.googlesource.com/c/chromium/src/+/1954347 diff --git a/content/public/renderer/content_renderer_client.h b/content/public/renderer/content_renderer_client.h -index 7da02ee54143e51dfb76d093429e3d8555517c4e..de0274d03ff1a0838f0ab0002c5a6b6ea7e10bfd 100644 +index 4cc9d55795035e6857f6e4ceb839d056d48c96cd..9d321040de33acac09e83cc582f685740f425009 100644 --- a/content/public/renderer/content_renderer_client.h +++ b/content/public/renderer/content_renderer_client.h -@@ -394,6 +394,11 @@ class CONTENT_EXPORT ContentRendererClient { +@@ -395,6 +395,11 @@ class CONTENT_EXPORT ContentRendererClient { virtual void DidInitializeWorkerContextOnWorkerThread( v8::Local context) {} @@ -67,10 +67,10 @@ index 6c813f0484f8ce2ef6e58b710a0117d3785f25f8..2872ee9d3a7b0eb888d332a7f7fe9354 const WebSecurityOrigin& script_origin) { return false; diff --git a/third_party/blink/renderer/core/workers/worker_thread.cc b/third_party/blink/renderer/core/workers/worker_thread.cc -index fe98ad619b9f5a8c13064daa80cc32bee4dc5c8c..87ab2c4ef183d9515758f6d92e732aaf8f53d09e 100644 +index f655c4ecc13e8445e35c6a79625946c9c7fb671b..32bac98ed79471178c36590b7db99fc1a95363b0 100644 --- a/third_party/blink/renderer/core/workers/worker_thread.cc +++ b/third_party/blink/renderer/core/workers/worker_thread.cc -@@ -687,6 +687,12 @@ void WorkerThread::PrepareForShutdownOnWorkerThread() { +@@ -686,6 +686,12 @@ void WorkerThread::PrepareForShutdownOnWorkerThread() { nested_runner_->QuitNow(); } diff --git a/patches/v8/add_realloc.patch b/patches/v8/add_realloc.patch index a3f0348ff88..807629c7953 100644 --- a/patches/v8/add_realloc.patch +++ b/patches/v8/add_realloc.patch @@ -12,7 +12,7 @@ when we override ReallocateBufferMemory, so we therefore need to implement Realloc on the v8 side. diff --git a/include/v8.h b/include/v8.h -index 18d72f1630ccd5ec54183d653a94c023848049fb..d25b81755a59e523828a967a8864dc179f9f4eeb 100644 +index 016cbb4de8f8bc82cbff4c4b03f933a9f3d063e9..d41c65f91480e8509e1250610885fe79b205ebf8 100644 --- a/include/v8.h +++ b/include/v8.h @@ -5051,6 +5051,13 @@ class V8_EXPORT ArrayBuffer : public Object { @@ -30,7 +30,7 @@ index 18d72f1630ccd5ec54183d653a94c023848049fb..d25b81755a59e523828a967a8864dc17 * Free the memory block of size |length|, pointed to by |data|. * That memory is guaranteed to be previously allocated by |Allocate|. diff --git a/src/api/api.cc b/src/api/api.cc -index c9bda37991502f74c485b42468a677c60c260dc8..9aa0ae27d40644e637fcd61df3ba0377a5b731fd 100644 +index d6f55b58cfb084321efbf6e60da5efaa3be45ae8..0ec463e787d55ce386afcdb9f5016f24e6cfcea4 100644 --- a/src/api/api.cc +++ b/src/api/api.cc @@ -528,6 +528,10 @@ void V8::SetSnapshotDataBlob(StartupData* snapshot_blob) { diff --git a/patches/v8/build_gn.patch b/patches/v8/build_gn.patch index 800accb739a..44d3a3622c6 100644 --- a/patches/v8/build_gn.patch +++ b/patches/v8/build_gn.patch @@ -9,10 +9,10 @@ necessary for native modules to load. Also, some fixes relating to mksnapshot on ARM. diff --git a/BUILD.gn b/BUILD.gn -index 44089412300d9f97ca15dec591d2ec928fdd6480..65dfa8dab947fc3f1b7dec0d8a7f1fcbdd773254 100644 +index cde17854138d7874dfb90d87ea389ecad1889682..829b3731a658e5fb991d9cb982c9219ab7e51837 100644 --- a/BUILD.gn +++ b/BUILD.gn -@@ -334,7 +334,7 @@ config("internal_config") { +@@ -341,7 +341,7 @@ config("internal_config") { ":v8_header_features", ] @@ -21,7 +21,7 @@ index 44089412300d9f97ca15dec591d2ec928fdd6480..65dfa8dab947fc3f1b7dec0d8a7f1fcb defines += [ "BUILDING_V8_SHARED" ] } } -@@ -4223,7 +4223,7 @@ if (current_toolchain == v8_generator_toolchain) { +@@ -4239,7 +4239,7 @@ if (current_toolchain == v8_generator_toolchain) { "src/interpreter/bytecodes.h", ] @@ -30,7 +30,7 @@ index 44089412300d9f97ca15dec591d2ec928fdd6480..65dfa8dab947fc3f1b7dec0d8a7f1fcb deps = [ ":v8_libbase", -@@ -4256,6 +4256,8 @@ if (current_toolchain == v8_snapshot_toolchain) { +@@ -4272,6 +4272,8 @@ if (current_toolchain == v8_snapshot_toolchain) { configs = [ ":internal_config" ] diff --git a/patches/v8/dcheck.patch b/patches/v8/dcheck.patch index 42f74996c0c..4ec6a026711 100644 --- a/patches/v8/dcheck.patch +++ b/patches/v8/dcheck.patch @@ -6,10 +6,10 @@ Subject: dcheck.patch https://github.com/auchenberg/volkswagen diff --git a/src/api/api.cc b/src/api/api.cc -index 9aa0ae27d40644e637fcd61df3ba0377a5b731fd..900f8bb8ff76c578de40f49729396b0a8b6052b9 100644 +index 0ec463e787d55ce386afcdb9f5016f24e6cfcea4..1746a75ea34b2ac1739bca326a1283fa4bf4f0d0 100644 --- a/src/api/api.cc +++ b/src/api/api.cc -@@ -8620,7 +8620,7 @@ void Isolate::SetPromiseRejectCallback(PromiseRejectCallback callback) { +@@ -8622,7 +8622,7 @@ void Isolate::SetPromiseRejectCallback(PromiseRejectCallback callback) { } void Isolate::PerformMicrotaskCheckpoint() { @@ -19,10 +19,10 @@ index 9aa0ae27d40644e637fcd61df3ba0377a5b731fd..900f8bb8ff76c578de40f49729396b0a isolate->default_microtask_queue()->PerformCheckpoint(this); } diff --git a/src/heap/heap.cc b/src/heap/heap.cc -index 0a0f56941f6cdceacf943bfb361af052c6f4b723..c9e36bd5c7cc0d59780ad6efa1291ce63f237b67 100644 +index 6099551b36225fbd34474707d0e4fdca783f8368..011cdceaf8dcaecb651af681fd6961ca6778f42d 100644 --- a/src/heap/heap.cc +++ b/src/heap/heap.cc -@@ -5625,9 +5625,9 @@ void Heap::TearDown() { +@@ -5629,9 +5629,9 @@ void Heap::TearDown() { void Heap::AddGCPrologueCallback(v8::Isolate::GCCallbackWithData callback, GCType gc_type, void* data) { DCHECK_NOT_NULL(callback); diff --git a/patches/v8/do_not_export_private_v8_symbols_on_windows.patch b/patches/v8/do_not_export_private_v8_symbols_on_windows.patch index bb8659be6eb..f7af3218abb 100644 --- a/patches/v8/do_not_export_private_v8_symbols_on_windows.patch +++ b/patches/v8/do_not_export_private_v8_symbols_on_windows.patch @@ -12,10 +12,10 @@ This patch can be safely removed if, when it is removed, `node.lib` does not contain any standard C++ library exports (e.g. `std::ostringstream`). diff --git a/BUILD.gn b/BUILD.gn -index 9f9a93828bb3ac56f208e582ccb97ca942be8e15..e3a14f4cd19dbad897098fd32c75464e6bca7286 100644 +index 635b9b3cddbd9d5698c7299a576b798e720439a3..5fd4439ae6f7525a935a20078da3af197195e4d4 100644 --- a/BUILD.gn +++ b/BUILD.gn -@@ -334,6 +334,10 @@ config("internal_config") { +@@ -341,6 +341,10 @@ config("internal_config") { ":v8_header_features", ] diff --git a/patches/v8/export_symbols_needed_for_windows_build.patch b/patches/v8/export_symbols_needed_for_windows_build.patch index ce9be1dfdcf..b18cdd8c51f 100644 --- a/patches/v8/export_symbols_needed_for_windows_build.patch +++ b/patches/v8/export_symbols_needed_for_windows_build.patch @@ -19,7 +19,7 @@ index a52865c23b37955345a4bfd75e952da472d6b68f..941c546e9a2c2efcea348667ab285b16 explicit inline Relocatable(Isolate* isolate); inline virtual ~Relocatable(); diff --git a/src/objects/ordered-hash-table.h b/src/objects/ordered-hash-table.h -index b587960432caf56601920678686480f2f1dd5abc..3c08eb044115db534eb880b867e0d03802dc9615 100644 +index 5f3c45a110aa48cf7c9c189d0e37e07193f06b75..01bfb2a73dbfb6d5a5d41baea946c783abfd1558 100644 --- a/src/objects/ordered-hash-table.h +++ b/src/objects/ordered-hash-table.h @@ -60,7 +60,7 @@ namespace internal { diff --git a/patches/v8/expose_mksnapshot.patch b/patches/v8/expose_mksnapshot.patch index 2bd56505133..08cb74b7c8e 100644 --- a/patches/v8/expose_mksnapshot.patch +++ b/patches/v8/expose_mksnapshot.patch @@ -6,10 +6,10 @@ Subject: expose_mksnapshot.patch Needed in order to target mksnapshot for mksnapshot zip. diff --git a/BUILD.gn b/BUILD.gn -index 65dfa8dab947fc3f1b7dec0d8a7f1fcbdd773254..9f9a93828bb3ac56f208e582ccb97ca942be8e15 100644 +index 829b3731a658e5fb991d9cb982c9219ab7e51837..635b9b3cddbd9d5698c7299a576b798e720439a3 100644 --- a/BUILD.gn +++ b/BUILD.gn -@@ -4234,7 +4234,6 @@ if (current_toolchain == v8_generator_toolchain) { +@@ -4250,7 +4250,6 @@ if (current_toolchain == v8_generator_toolchain) { if (current_toolchain == v8_snapshot_toolchain) { v8_executable("mksnapshot") { diff --git a/shell/browser/api/electron_api_browser_window.cc b/shell/browser/api/electron_api_browser_window.cc index 9bcb293e749..094e4e4ed5d 100644 --- a/shell/browser/api/electron_api_browser_window.cc +++ b/shell/browser/api/electron_api_browser_window.cc @@ -210,7 +210,7 @@ void BrowserWindow::OnCloseContents() { window_unresponsive_closure_.Cancel(); } -void BrowserWindow::OnRendererResponsive() { +void BrowserWindow::OnRendererResponsive(content::RenderProcessHost*) { window_unresponsive_closure_.Cancel(); Emit("responsive"); } diff --git a/shell/browser/api/electron_api_browser_window.h b/shell/browser/api/electron_api_browser_window.h index 37825d527c9..a3c225fe6fa 100644 --- a/shell/browser/api/electron_api_browser_window.h +++ b/shell/browser/api/electron_api_browser_window.h @@ -51,10 +51,11 @@ class BrowserWindow : public TopLevelWindow, void DidFirstVisuallyNonEmptyPaint() override; void BeforeUnloadDialogCancelled() override; void OnRendererUnresponsive(content::RenderProcessHost*) override; + void OnRendererResponsive( + content::RenderProcessHost* render_process_host) override; // ExtendedWebContentsObserver: void OnCloseContents() override; - void OnRendererResponsive() override; void OnDraggableRegionsUpdated( const std::vector& regions) override; void OnSetContentBounds(const gfx::Rect& rect) override; diff --git a/shell/browser/api/electron_api_web_contents.cc b/shell/browser/api/electron_api_web_contents.cc index 44ec8dbd81e..69b7efeb8f0 100644 --- a/shell/browser/api/electron_api_web_contents.cc +++ b/shell/browser/api/electron_api_web_contents.cc @@ -823,25 +823,25 @@ void WebContents::ContentsZoomChange(bool zoom_in) { } void WebContents::EnterFullscreenModeForTab( - content::WebContents* source, - const GURL& origin, + content::RenderFrameHost* requesting_frame, const blink::mojom::FullscreenOptions& options) { + auto* source = content::WebContents::FromRenderFrameHost(requesting_frame); auto* permission_helper = WebContentsPermissionHelper::FromWebContents(source); auto callback = base::BindRepeating(&WebContents::OnEnterFullscreenModeForTab, - base::Unretained(this), source, origin, options); + base::Unretained(this), requesting_frame, options); permission_helper->RequestFullscreenPermission(callback); } void WebContents::OnEnterFullscreenModeForTab( - content::WebContents* source, - const GURL& origin, + content::RenderFrameHost* requesting_frame, const blink::mojom::FullscreenOptions& options, bool allowed) { if (!allowed) return; - CommonWebContentsDelegate::EnterFullscreenModeForTab(source, origin, options); + CommonWebContentsDelegate::EnterFullscreenModeForTab(requesting_frame, + options); Emit("enter-html-full-screen"); } @@ -861,8 +861,6 @@ void WebContents::RendererResponsive( content::WebContents* source, content::RenderWidgetHost* render_widget_host) { Emit("responsive"); - for (ExtendedWebContentsObserver& observer : observers_) - observer.OnRendererResponsive(); } bool WebContents::HandleContextMenu(content::RenderFrameHost* render_frame_host, diff --git a/shell/browser/api/electron_api_web_contents.h b/shell/browser/api/electron_api_web_contents.h index f24ee5e9b26..c96e67862b7 100644 --- a/shell/browser/api/electron_api_web_contents.h +++ b/shell/browser/api/electron_api_web_contents.h @@ -116,7 +116,6 @@ namespace api { class ExtendedWebContentsObserver : public base::CheckedObserver { public: virtual void OnCloseContents() {} - virtual void OnRendererResponsive() {} virtual void OnDraggableRegionsUpdated( const std::vector& regions) {} virtual void OnSetContentBounds(const gfx::Rect& rect) {} @@ -340,8 +339,7 @@ class WebContents : public gin_helper::TrackableObject, // Callback triggered on permission response. void OnEnterFullscreenModeForTab( - content::WebContents* source, - const GURL& origin, + content::RenderFrameHost* requesting_frame, const blink::mojom::FullscreenOptions& options, bool allowed); @@ -471,8 +469,7 @@ class WebContents : public gin_helper::TrackableObject, const content::NativeWebKeyboardEvent& event) override; void ContentsZoomChange(bool zoom_in) override; void EnterFullscreenModeForTab( - content::WebContents* source, - const GURL& origin, + content::RenderFrameHost* requesting_frame, const blink::mojom::FullscreenOptions& options) override; void ExitFullscreenModeForTab(content::WebContents* source) override; void RendererUnresponsive( diff --git a/shell/browser/common_web_contents_delegate.cc b/shell/browser/common_web_contents_delegate.cc index a50c037bdfc..8f7e66c8eaf 100644 --- a/shell/browser/common_web_contents_delegate.cc +++ b/shell/browser/common_web_contents_delegate.cc @@ -350,11 +350,11 @@ void CommonWebContentsDelegate::EnumerateDirectory( } void CommonWebContentsDelegate::EnterFullscreenModeForTab( - content::WebContents* source, - const GURL& origin, + content::RenderFrameHost* requesting_frame, const blink::mojom::FullscreenOptions& options) { if (!owner_window_) return; + auto* source = content::WebContents::FromRenderFrameHost(requesting_frame); if (IsFullscreenForTabOrPending(source)) { DCHECK_EQ(fullscreen_frame_, source->GetFocusedFrame()); return; diff --git a/shell/browser/common_web_contents_delegate.h b/shell/browser/common_web_contents_delegate.h index 456e86274e1..2169b83f9ea 100644 --- a/shell/browser/common_web_contents_delegate.h +++ b/shell/browser/common_web_contents_delegate.h @@ -90,8 +90,7 @@ class CommonWebContentsDelegate : public content::WebContentsDelegate, std::unique_ptr listener, const base::FilePath& path) override; void EnterFullscreenModeForTab( - content::WebContents* source, - const GURL& origin, + content::RenderFrameHost* requesting_frame, const blink::mojom::FullscreenOptions& options) override; void ExitFullscreenModeForTab(content::WebContents* source) override; bool IsFullscreenForTabOrPending(const content::WebContents* source) override; diff --git a/shell/browser/native_window_views.cc b/shell/browser/native_window_views.cc index 318aad4340b..a871b096a19 100644 --- a/shell/browser/native_window_views.cc +++ b/shell/browser/native_window_views.cc @@ -956,9 +956,9 @@ void NativeWindowViews::SetIgnoreMouseEvents(bool ignore, bool forward) { #elif defined(USE_X11) if (ignore) { XRectangle r = {0, 0, 1, 1}; - XShapeCombineRectangles( - gfx::GetXDisplay(), GetAcceleratedWidget(), ShapeInput, 0, 0, &r, 1, - ShapeSet, static_cast(x11::XProto::ClipOrdering::YXBanded)); + XShapeCombineRectangles(gfx::GetXDisplay(), GetAcceleratedWidget(), + ShapeInput, 0, 0, &r, 1, ShapeSet, + static_cast(x11::ClipOrdering::YXBanded)); } else { XShapeCombineMask(gfx::GetXDisplay(), GetAcceleratedWidget(), ShapeInput, 0, 0, x11::None, ShapeSet); diff --git a/shell/browser/net/system_network_context_manager.cc b/shell/browser/net/system_network_context_manager.cc index 054a6e9f4e1..d9c85383c02 100644 --- a/shell/browser/net/system_network_context_manager.cc +++ b/shell/browser/net/system_network_context_manager.cc @@ -208,8 +208,6 @@ void SystemNetworkContextManager::OnNetworkServiceCreated( network_service->SetUpHttpAuth(CreateHttpAuthStaticParams()); network_service->ConfigureHttpAuthPrefs(CreateHttpAuthDynamicParams()); - // The system NetworkContext must be created first, since it sets - // |primary_network_context| to true. network_context_.reset(); network_service->CreateNetworkContext( network_context_.BindNewPipeAndPassReceiver(), @@ -229,8 +227,6 @@ SystemNetworkContextManager::CreateNetworkContextParams() { network_context_params->http_cache_enabled = false; - network_context_params->primary_network_context = true; - proxy_config_monitor_.AddToNetworkContextParams(network_context_params.get()); return network_context_params; diff --git a/shell/browser/printing/print_preview_message_handler.cc b/shell/browser/printing/print_preview_message_handler.cc index 48ec8a5f911..c83a251d38f 100644 --- a/shell/browser/printing/print_preview_message_handler.cc +++ b/shell/browser/printing/print_preview_message_handler.cc @@ -79,7 +79,7 @@ void PrintPreviewMessageHandler::OnMetafileReadyForPrinting( // Always try to stop the worker. StopWorker(params.document_cookie); - const PrintHostMsg_DidPrintContent_Params& content = params.content; + const printing::mojom::DidPrintContentParams& content = params.content; if (!content.metafile_data_region.IsValid() || params.expected_pages_count <= 0) { RejectPromise(ids.request_id); diff --git a/shell/browser/ui/x/x_window_utils.cc b/shell/browser/ui/x/x_window_utils.cc index 0c99fd27a06..e71e65697fd 100644 --- a/shell/browser/ui/x/x_window_utils.cc +++ b/shell/browser/ui/x/x_window_utils.cc @@ -99,8 +99,7 @@ void MoveWindowAbove(::Window xwindow, ::Window other_xwindow) { xclient.xclient.format = 32; xclient.xclient.data.l[0] = 2; xclient.xclient.data.l[1] = other_xwindow; - xclient.xclient.data.l[2] = - static_cast(x11::Connection::StackMode::Above); + xclient.xclient.data.l[2] = static_cast(x11::StackMode::Above); xclient.xclient.data.l[3] = 0; xclient.xclient.data.l[4] = 0; diff --git a/spec-main/api-browser-window-spec.ts b/spec-main/api-browser-window-spec.ts index c4c8b9bd3ce..de410580ec1 100644 --- a/spec-main/api-browser-window-spec.ts +++ b/spec-main/api-browser-window-spec.ts @@ -1,4 +1,5 @@ import { expect } from 'chai'; +import * as childProcess from 'child_process'; import * as path from 'path'; import * as fs from 'fs'; import * as os from 'os'; @@ -55,6 +56,12 @@ describe('BrowserWindow module', () => { w.destroy(); }).not.to.throw(); }); + + ifit(process.platform === 'linux')('does not crash when setting large window icons', async () => { + const appPath = path.join(__dirname, 'spec-main', 'fixtures', 'apps', 'xwindow-icon'); + const appProcess = childProcess.spawn(process.execPath, [appPath]); + await new Promise((resolve) => { appProcess.once('exit', resolve); }); + }); }); describe('garbage collection', () => { diff --git a/spec-main/fixtures/apps/xwindow-icon/icon.png b/spec-main/fixtures/apps/xwindow-icon/icon.png new file mode 100644 index 00000000000..bc527dda8ae Binary files /dev/null and b/spec-main/fixtures/apps/xwindow-icon/icon.png differ diff --git a/spec-main/fixtures/apps/xwindow-icon/main.js b/spec-main/fixtures/apps/xwindow-icon/main.js new file mode 100644 index 00000000000..0da98ad277c --- /dev/null +++ b/spec-main/fixtures/apps/xwindow-icon/main.js @@ -0,0 +1,13 @@ +const { app, BrowserWindow } = require('electron'); +const path = require('path'); + +app.whenReady().then(() => { + const w = new BrowserWindow({ + show: false, + icon: path.join(__dirname, 'icon.png') + }); + w.webContents.on('did-finish-load', () => { + app.quit(); + }); + w.loadURL('about:blank'); +}); diff --git a/spec-main/fixtures/apps/xwindow-icon/package.json b/spec-main/fixtures/apps/xwindow-icon/package.json new file mode 100644 index 00000000000..595e59b0f0f --- /dev/null +++ b/spec-main/fixtures/apps/xwindow-icon/package.json @@ -0,0 +1,4 @@ +{ + "name": "electron-xwindow-icon", + "main": "main.js" + } \ No newline at end of file