From 00d4ad546e8e9571991b4ecc4d7cc28a4d8836cf Mon Sep 17 00:00:00 2001 From: Marshall Greenblatt Date: Wed, 20 Oct 2021 17:38:49 -0400 Subject: [PATCH] Update to Chromium version 95.0.4638.54 --- CHROMIUM_BUILD_COMPATIBILITY.txt | 2 +- .../browser_security_policy_1081397.patch | 6 ++--- patch/patches/chrome_browser.patch | 4 +-- patch/patches/chrome_browser_browser.patch | 4 +-- .../chrome_browser_context_menus.patch | 16 ++++++------ patch/patches/chrome_browser_net_export.patch | 4 +-- patch/patches/chrome_browser_profiles.patch | 4 +-- patch/patches/chrome_renderer.patch | 2 +- patch/patches/chrome_runtime_views.patch | 14 +++++------ patch/patches/content_2015.patch | 25 ++++++++++--------- patch/patches/rwh_background_color_1984.patch | 2 +- patch/patches/views_widget.patch | 4 +-- patch/patches/web_contents_1257_1565.patch | 4 +-- patch/patches/webview_plugin_2020.patch | 2 +- 14 files changed, 47 insertions(+), 46 deletions(-) diff --git a/CHROMIUM_BUILD_COMPATIBILITY.txt b/CHROMIUM_BUILD_COMPATIBILITY.txt index 4b0b06583..c37c8bc7e 100644 --- a/CHROMIUM_BUILD_COMPATIBILITY.txt +++ b/CHROMIUM_BUILD_COMPATIBILITY.txt @@ -7,6 +7,6 @@ # https://bitbucket.org/chromiumembedded/cef/wiki/BranchesAndBuilding { - 'chromium_checkout': 'refs/tags/95.0.4638.17', + 'chromium_checkout': 'refs/tags/95.0.4638.54', 'depot_tools_checkout': 'eff810e93d' } diff --git a/patch/patches/browser_security_policy_1081397.patch b/patch/patches/browser_security_policy_1081397.patch index a1e63fc1e..0aa307a0c 100644 --- a/patch/patches/browser_security_policy_1081397.patch +++ b/patch/patches/browser_security_policy_1081397.patch @@ -20,10 +20,10 @@ index 5daa087a01e80..316ec852394a4 100644 // TODO(wjmaclean): We should update the ProcessLock comparison API diff --git content/browser/renderer_host/navigation_request.cc content/browser/renderer_host/navigation_request.cc -index f1136b6502573..654397a5a9f76 100644 +index d950678294a9a..f71549b91b591 100644 --- content/browser/renderer_host/navigation_request.cc +++ content/browser/renderer_host/navigation_request.cc -@@ -5803,6 +5803,12 @@ NavigationRequest::GetOriginForURLLoaderFactoryWithoutFinalFrameHost( +@@ -5822,6 +5822,12 @@ NavigationRequest::GetOriginForURLLoaderFactoryWithoutFinalFrameHost( network::mojom::WebSandboxFlags sandbox_flags) { // Calculate an approximation of the origin. The sandbox/csp are ignored. url::Origin origin = GetOriginForURLLoaderFactoryUnchecked(this); @@ -36,7 +36,7 @@ index f1136b6502573..654397a5a9f76 100644 // Apply sandbox flags. // See https://html.spec.whatwg.org/#sandboxed-origin-browsing-context-flag -@@ -5836,6 +5842,15 @@ NavigationRequest::GetOriginForURLLoaderFactoryWithFinalFrameHost() { +@@ -5855,6 +5861,15 @@ NavigationRequest::GetOriginForURLLoaderFactoryWithFinalFrameHost() { if (IsSameDocument() || IsPageActivation()) return GetRenderFrameHost()->GetLastCommittedOrigin(); diff --git a/patch/patches/chrome_browser.patch b/patch/patches/chrome_browser.patch index ae81fb25c..7d6157a09 100644 --- a/patch/patches/chrome_browser.patch +++ b/patch/patches/chrome_browser.patch @@ -1,5 +1,5 @@ diff --git chrome/browser/BUILD.gn chrome/browser/BUILD.gn -index 69032e4832aa8..f62f1d353ee99 100644 +index 442c7056f978e..a6cdd9c9e8bc5 100644 --- chrome/browser/BUILD.gn +++ chrome/browser/BUILD.gn @@ -13,6 +13,7 @@ import("//build/config/features.gni") @@ -18,7 +18,7 @@ index 69032e4832aa8..f62f1d353ee99 100644 "//chrome:extra_resources", "//chrome:resources", "//chrome:strings", -@@ -2512,6 +2514,10 @@ static_library("browser") { +@@ -2513,6 +2515,10 @@ static_library("browser") { ] } diff --git a/patch/patches/chrome_browser_browser.patch b/patch/patches/chrome_browser_browser.patch index cba3f0630..eee0e3d10 100644 --- a/patch/patches/chrome_browser_browser.patch +++ b/patch/patches/chrome_browser_browser.patch @@ -200,7 +200,7 @@ index 2beb437bedf1d..21b15b48b4a3e 100644 void Browser::TabDetachedAtImpl(content::WebContents* contents, diff --git chrome/browser/ui/browser.h chrome/browser/ui/browser.h -index 7649c59dde3f5..a3b719f5c673a 100644 +index 599a822375fc7..90b3658ef3fe9 100644 --- chrome/browser/ui/browser.h +++ chrome/browser/ui/browser.h @@ -21,6 +21,7 @@ @@ -261,7 +261,7 @@ index 7649c59dde3f5..a3b719f5c673a 100644 // Get the FindBarController for this browser, creating it if it does not // yet exist. FindBarController* GetFindBarController(); -@@ -793,6 +816,11 @@ class Browser : public TabStripModelObserver, +@@ -796,6 +819,11 @@ class Browser : public TabStripModelObserver, void SetContentsBounds(content::WebContents* source, const gfx::Rect& bounds) override; void UpdateTargetURL(content::WebContents* source, const GURL& url) override; diff --git a/patch/patches/chrome_browser_context_menus.patch b/patch/patches/chrome_browser_context_menus.patch index 75abb83ef..11a8655d8 100644 --- a/patch/patches/chrome_browser_context_menus.patch +++ b/patch/patches/chrome_browser_context_menus.patch @@ -1,8 +1,8 @@ diff --git chrome/browser/renderer_context_menu/render_view_context_menu.cc chrome/browser/renderer_context_menu/render_view_context_menu.cc -index 24d40c76da899..a05d78416b7eb 100644 +index dc7dbd4b527bb..171871cedc3df 100644 --- chrome/browser/renderer_context_menu/render_view_context_menu.cc +++ chrome/browser/renderer_context_menu/render_view_context_menu.cc -@@ -283,6 +283,13 @@ base::OnceCallback* GetMenuShownCallback() { +@@ -280,6 +280,13 @@ base::OnceCallback* GetMenuShownCallback() { return callback.get(); } @@ -16,7 +16,7 @@ index 24d40c76da899..a05d78416b7eb 100644 enum class UmaEnumIdLookupType { GeneralEnumId, ContextSpecificEnumId, -@@ -494,6 +501,10 @@ int FindUMAEnumValueForCommand(int id, UmaEnumIdLookupType type) { +@@ -493,6 +500,10 @@ int FindUMAEnumValueForCommand(int id, UmaEnumIdLookupType type) { if (ContextMenuMatcher::IsExtensionsCustomCommandId(id)) return 1; @@ -27,7 +27,7 @@ index 24d40c76da899..a05d78416b7eb 100644 id = CollapseCommandsForUMA(id); const auto& map = GetIdcToUmaMap(type); auto it = map.find(id); -@@ -670,6 +681,14 @@ RenderViewContextMenu::RenderViewContextMenu( +@@ -669,6 +680,14 @@ RenderViewContextMenu::RenderViewContextMenu( system_app_ = GetBrowser() && GetBrowser()->app_controller() ? GetBrowser()->app_controller()->system_app() : nullptr; @@ -42,7 +42,7 @@ index 24d40c76da899..a05d78416b7eb 100644 } RenderViewContextMenu::~RenderViewContextMenu() = default; -@@ -1026,6 +1045,12 @@ void RenderViewContextMenu::InitMenu() { +@@ -1025,6 +1044,12 @@ void RenderViewContextMenu::InitMenu() { // menu, meaning that each menu item added/removed in this function will cause // it to visibly jump on the screen (see b/173569669). AppendQuickAnswersItems(); @@ -55,7 +55,7 @@ index 24d40c76da899..a05d78416b7eb 100644 } Profile* RenderViewContextMenu::GetProfile() const { -@@ -2824,6 +2849,12 @@ void RenderViewContextMenu::RegisterMenuShownCallbackForTesting( +@@ -2843,6 +2868,12 @@ void RenderViewContextMenu::RegisterMenuShownCallbackForTesting( *GetMenuShownCallback() = std::move(cb); } @@ -69,10 +69,10 @@ index 24d40c76da899..a05d78416b7eb 100644 RenderViewContextMenu::GetHandlersForLinkUrl() { ProtocolHandlerRegistry::ProtocolHandlerList handlers = diff --git chrome/browser/renderer_context_menu/render_view_context_menu.h chrome/browser/renderer_context_menu/render_view_context_menu.h -index 196a699745061..849303df95a32 100644 +index 526f116a0578b..27ec366c6ad77 100644 --- chrome/browser/renderer_context_menu/render_view_context_menu.h +++ chrome/browser/renderer_context_menu/render_view_context_menu.h -@@ -111,6 +111,12 @@ class RenderViewContextMenu : public RenderViewContextMenuBase, +@@ -110,6 +110,12 @@ class RenderViewContextMenu : public RenderViewContextMenuBase, static void RegisterMenuShownCallbackForTesting( base::OnceCallback cb); diff --git a/patch/patches/chrome_browser_net_export.patch b/patch/patches/chrome_browser_net_export.patch index de05b6507..ead0c1669 100644 --- a/patch/patches/chrome_browser_net_export.patch +++ b/patch/patches/chrome_browser_net_export.patch @@ -1,5 +1,5 @@ diff --git chrome/browser/ui/BUILD.gn chrome/browser/ui/BUILD.gn -index a6161392b2698..bab517eeb3a9e 100644 +index fa876edb9ae6f..306bcb400d0fc 100644 --- chrome/browser/ui/BUILD.gn +++ chrome/browser/ui/BUILD.gn @@ -11,6 +11,7 @@ import("//build/config/features.gni") @@ -29,7 +29,7 @@ index a6161392b2698..bab517eeb3a9e 100644 "//chrome:extra_resources", "//chrome:resources", "//chrome:strings", -@@ -4990,6 +4996,7 @@ static_library("ui") { +@@ -4992,6 +4998,7 @@ static_library("ui") { if (enable_basic_printing) { deps += [ "//components/printing/browser", diff --git a/patch/patches/chrome_browser_profiles.patch b/patch/patches/chrome_browser_profiles.patch index 2bb762786..ed319e58a 100644 --- a/patch/patches/chrome_browser_profiles.patch +++ b/patch/patches/chrome_browser_profiles.patch @@ -85,10 +85,10 @@ index bf7fc55a91e20..d6209550b6567 100644 virtual bool IsSignedIn() = 0; diff --git chrome/browser/profiles/profile_impl.cc chrome/browser/profiles/profile_impl.cc -index 56ce2f16cdd12..82e8d76090ce1 100644 +index 4d9987407277f..c5c1ed73e1212 100644 --- chrome/browser/profiles/profile_impl.cc +++ chrome/browser/profiles/profile_impl.cc -@@ -1026,7 +1026,9 @@ Profile* ProfileImpl::GetOffTheRecordProfile(const OTRProfileID& otr_profile_id, +@@ -1027,7 +1027,9 @@ Profile* ProfileImpl::GetOffTheRecordProfile(const OTRProfileID& otr_profile_id, otr_profiles_[otr_profile_id] = std::move(otr_profile); diff --git a/patch/patches/chrome_renderer.patch b/patch/patches/chrome_renderer.patch index 24eb2712e..34dfbefcf 100644 --- a/patch/patches/chrome_renderer.patch +++ b/patch/patches/chrome_renderer.patch @@ -1,5 +1,5 @@ diff --git chrome/renderer/BUILD.gn chrome/renderer/BUILD.gn -index fdbff76b66227..d8b6453dffcac 100644 +index f8ad4b2fe2646..9eee4d5d7a42b 100644 --- chrome/renderer/BUILD.gn +++ chrome/renderer/BUILD.gn @@ -5,6 +5,7 @@ diff --git a/patch/patches/chrome_runtime_views.patch b/patch/patches/chrome_runtime_views.patch index 5eb2cadd0..86ae97298 100644 --- a/patch/patches/chrome_runtime_views.patch +++ b/patch/patches/chrome_runtime_views.patch @@ -120,7 +120,7 @@ index e06cd6c3d83db..1f7da7cf79979 100644 // Initialize the frame (creates the underlying native window). diff --git chrome/browser/ui/views/frame/browser_view.cc chrome/browser/ui/views/frame/browser_view.cc -index e7081ab3ec3e8..eb533496ef91c 100644 +index 61077f70f8a96..85f1d10dea443 100644 --- chrome/browser/ui/views/frame/browser_view.cc +++ chrome/browser/ui/views/frame/browser_view.cc @@ -284,11 +284,10 @@ using content::WebContents; @@ -197,7 +197,7 @@ index e7081ab3ec3e8..eb533496ef91c 100644 return frame_->GetFrameView()->ShouldHideTopUIForFullscreen(); } -@@ -2545,7 +2563,8 @@ BrowserView::GetNativeViewHostsForTopControlsSlide() const { +@@ -2554,7 +2572,8 @@ BrowserView::GetNativeViewHostsForTopControlsSlide() const { } void BrowserView::ReparentTopContainerForEndOfImmersive() { @@ -207,7 +207,7 @@ index e7081ab3ec3e8..eb533496ef91c 100644 top_container()->DestroyLayer(); AddChildViewAt(top_container(), 0); EnsureFocusOrder(); -@@ -2997,8 +3016,10 @@ void BrowserView::Layout() { +@@ -3006,8 +3025,10 @@ void BrowserView::Layout() { // TODO(jamescook): Why was this in the middle of layout code? toolbar_->location_bar()->omnibox_view()->SetFocusBehavior( @@ -220,7 +220,7 @@ index e7081ab3ec3e8..eb533496ef91c 100644 // Some of the situations when the BrowserView is laid out are: // - Enter/exit immersive fullscreen mode. -@@ -3061,6 +3082,11 @@ void BrowserView::AddedToWidget() { +@@ -3070,6 +3091,11 @@ void BrowserView::AddedToWidget() { SetThemeProfileForWindow(GetNativeWindow(), browser_->profile()); #endif @@ -232,7 +232,7 @@ index e7081ab3ec3e8..eb533496ef91c 100644 toolbar_->Init(); #if BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_CHROMEOS_LACROS) -@@ -3096,13 +3122,9 @@ void BrowserView::AddedToWidget() { +@@ -3105,13 +3131,9 @@ void BrowserView::AddedToWidget() { EnsureFocusOrder(); @@ -249,7 +249,7 @@ index e7081ab3ec3e8..eb533496ef91c 100644 MaybeInitializeWebUITabStrip(); diff --git chrome/browser/ui/views/frame/browser_view.h chrome/browser/ui/views/frame/browser_view.h -index a9ba4f9841ef4..a373c1a1f1e90 100644 +index c628d5143c8bc..953e930d6bce8 100644 --- chrome/browser/ui/views/frame/browser_view.h +++ chrome/browser/ui/views/frame/browser_view.h @@ -121,11 +121,16 @@ class BrowserView : public BrowserWindow, @@ -269,7 +269,7 @@ index a9ba4f9841ef4..a373c1a1f1e90 100644 void set_frame(BrowserFrame* frame) { frame_ = frame; } BrowserFrame* frame() const { return frame_; } -@@ -684,6 +689,12 @@ class BrowserView : public BrowserWindow, +@@ -685,6 +690,12 @@ class BrowserView : public BrowserWindow, return accessibility_focus_highlight_.get(); } diff --git a/patch/patches/content_2015.patch b/patch/patches/content_2015.patch index e3e9d20ba..0829af591 100644 --- a/patch/patches/content_2015.patch +++ b/patch/patches/content_2015.patch @@ -188,10 +188,10 @@ index 632ae86c6fd69..55b749ec12421 100644 const std::vector& all_plugins); diff --git content/browser/renderer_host/render_frame_host_impl.cc content/browser/renderer_host/render_frame_host_impl.cc -index 974823d53b583..f5d635cd92889 100644 +index 0b3cc858e55b3..ae2428a7b0d68 100644 --- content/browser/renderer_host/render_frame_host_impl.cc +++ content/browser/renderer_host/render_frame_host_impl.cc -@@ -12408,6 +12408,7 @@ void RenderFrameHostImpl::BindHungDetectorHost( +@@ -12431,6 +12431,7 @@ void RenderFrameHostImpl::BindHungDetectorHost( } void RenderFrameHostImpl::GetPluginInfo(const GURL& url, @@ -199,7 +199,7 @@ index 974823d53b583..f5d635cd92889 100644 const url::Origin& main_frame_origin, const std::string& mime_type, GetPluginInfoCallback callback) { -@@ -12415,7 +12416,8 @@ void RenderFrameHostImpl::GetPluginInfo(const GURL& url, +@@ -12438,7 +12439,8 @@ void RenderFrameHostImpl::GetPluginInfo(const GURL& url, WebPluginInfo info; std::string actual_mime_type; bool found = PluginServiceImpl::GetInstance()->GetPluginInfo( @@ -210,10 +210,10 @@ index 974823d53b583..f5d635cd92889 100644 std::move(callback).Run(found, info, actual_mime_type); } diff --git content/browser/renderer_host/render_frame_host_impl.h content/browser/renderer_host/render_frame_host_impl.h -index 53cc68edc7fd7..b8b6698f65e9d 100644 +index cfa08c48e66e4..638e79ca69fc9 100644 --- content/browser/renderer_host/render_frame_host_impl.h +++ content/browser/renderer_host/render_frame_host_impl.h -@@ -2611,6 +2611,7 @@ class CONTENT_EXPORT RenderFrameHostImpl +@@ -2617,6 +2617,7 @@ class CONTENT_EXPORT RenderFrameHostImpl int32_t plugin_child_id, const base::FilePath& path) override; void GetPluginInfo(const GURL& url, @@ -361,30 +361,31 @@ index c0a004136c09c..5fbf7092b07ad 100644 &RenderThreadImpl::OnRendererInterfaceReceiver, base::Unretained(this))); diff --git content/renderer/renderer_blink_platform_impl.cc content/renderer/renderer_blink_platform_impl.cc -index 337c630fc85f3..20abead97fe1d 100644 +index 0280650b9c9b4..3c91de7baf061 100644 --- content/renderer/renderer_blink_platform_impl.cc +++ content/renderer/renderer_blink_platform_impl.cc -@@ -1101,6 +1101,15 @@ SkBitmap* RendererBlinkPlatformImpl::GetSadPageBitmap() { +@@ -1105,6 +1105,16 @@ SkBitmap* RendererBlinkPlatformImpl::GetSadPageBitmap() { //------------------------------------------------------------------------------ +void RendererBlinkPlatformImpl::DevToolsAgentAttached() { + GetContentClient()->renderer()->DevToolsAgentAttached(); +} ++ +void RendererBlinkPlatformImpl::DevToolsAgentDetached() { + GetContentClient()->renderer()->DevToolsAgentDetached(); +} + +//------------------------------------------------------------------------------ + - blink::mojom::CodeCacheHost& RendererBlinkPlatformImpl::GetCodeCacheHost() { - if (!code_cache_host_) { - code_cache_host_ = mojo::SharedRemote( + mojo::SharedRemote + RendererBlinkPlatformImpl::GetCodeCacheHost() { + base::AutoLock lock(code_cache_host_lock_); diff --git content/renderer/renderer_blink_platform_impl.h content/renderer/renderer_blink_platform_impl.h -index b199c34615f02..43ced4c4d8cf5 100644 +index 577ba7b677366..7549e2f92ea95 100644 --- content/renderer/renderer_blink_platform_impl.h +++ content/renderer/renderer_blink_platform_impl.h -@@ -258,6 +258,9 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl { +@@ -260,6 +260,9 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl { const blink::WebURL& url, blink::WebVector* csp) override; diff --git a/patch/patches/rwh_background_color_1984.patch b/patch/patches/rwh_background_color_1984.patch index a579307b4..81d67b7f3 100644 --- a/patch/patches/rwh_background_color_1984.patch +++ b/patch/patches/rwh_background_color_1984.patch @@ -1,5 +1,5 @@ diff --git content/browser/renderer_host/render_widget_host_view_aura.cc content/browser/renderer_host/render_widget_host_view_aura.cc -index 28e9a059a5c22..f9de44e10828f 100644 +index 7170f19b652dd..6c5149f6c492f 100644 --- content/browser/renderer_host/render_widget_host_view_aura.cc +++ content/browser/renderer_host/render_widget_host_view_aura.cc @@ -656,10 +656,12 @@ gfx::Rect RenderWidgetHostViewAura::GetViewBounds() { diff --git a/patch/patches/views_widget.patch b/patch/patches/views_widget.patch index c360ac5f9..db45e6d37 100644 --- a/patch/patches/views_widget.patch +++ b/patch/patches/views_widget.patch @@ -130,10 +130,10 @@ index 7a8ceb1916434..01d0ca9a19316 100644 // Set the view's active state (i.e., tint state of controls). virtual void SetActive(bool active) = 0; diff --git ui/platform_window/x11/x11_window.cc ui/platform_window/x11/x11_window.cc -index 030c1e3c4ade5..d4776e596f250 100644 +index 30a1e53896075..ee1f7168bb9c6 100644 --- ui/platform_window/x11/x11_window.cc +++ ui/platform_window/x11/x11_window.cc -@@ -1677,7 +1677,8 @@ void X11Window::CreateXWindow(const PlatformWindowInitProperties& properties) { +@@ -1694,7 +1694,8 @@ void X11Window::CreateXWindow(const PlatformWindowInitProperties& properties) { req.border_pixel = 0; bounds_in_pixels_ = SanitizeBounds(bounds); diff --git a/patch/patches/web_contents_1257_1565.patch b/patch/patches/web_contents_1257_1565.patch index cf283b446..0bdf39222 100644 --- a/patch/patches/web_contents_1257_1565.patch +++ b/patch/patches/web_contents_1257_1565.patch @@ -1,5 +1,5 @@ diff --git content/browser/web_contents/web_contents_impl.cc content/browser/web_contents/web_contents_impl.cc -index 55a636ca71a25..41dcccd02b4fa 100644 +index 40f11aa76845a..4e43e25230263 100644 --- content/browser/web_contents/web_contents_impl.cc +++ content/browser/web_contents/web_contents_impl.cc @@ -2881,6 +2881,12 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) { @@ -39,7 +39,7 @@ index 55a636ca71a25..41dcccd02b4fa 100644 std::unique_ptr new_contents; if (!is_guest) { create_params.context = view_->GetNativeView(); -@@ -7500,6 +7516,9 @@ void WebContentsImpl::SetFocusedFrame(FrameTreeNode* node, +@@ -7504,6 +7520,9 @@ void WebContentsImpl::SetFocusedFrame(FrameTreeNode* node, // This is an outermost WebContents. SetAsFocusedWebContentsIfNecessary(); } diff --git a/patch/patches/webview_plugin_2020.patch b/patch/patches/webview_plugin_2020.patch index 4cce0d2ad..1ea3c5050 100644 --- a/patch/patches/webview_plugin_2020.patch +++ b/patch/patches/webview_plugin_2020.patch @@ -1,5 +1,5 @@ diff --git chrome/app/generated_resources.grd chrome/app/generated_resources.grd -index 0b1ae29ed8f18..918f42f2f3d69 100644 +index 2606496900ccc..0f410526ba358 100644 --- chrome/app/generated_resources.grd +++ chrome/app/generated_resources.grd @@ -5327,7 +5327,7 @@ Keep your key file in a safe place. You will need it to create new versions of y