From 2156c9fd5d72f9cff30b9345396eed56e4bd1784 Mon Sep 17 00:00:00 2001 From: Marshall Greenblatt Date: Sat, 11 May 2024 11:23:56 -0400 Subject: [PATCH] Apply raw_ptr usage in patch files (see #3239) --- patch/patches/extensions_1947.patch | 4 ++-- patch/patches/osr_fling_2745.patch | 9 ++++++--- patch/patches/viz_osr_2575.patch | 4 ++-- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/patch/patches/extensions_1947.patch b/patch/patches/extensions_1947.patch index 5ba39a662..8721adbf4 100644 --- a/patch/patches/extensions_1947.patch +++ b/patch/patches/extensions_1947.patch @@ -136,7 +136,7 @@ index 5a0ba568bf30c..8ef4be85e038a 100644 ExtensionRegistry::Get(browser_context_)->RemoveObserver(this); diff --git extensions/browser/extension_host.h extensions/browser/extension_host.h -index 28ba09319b047..2a097a5ae4c16 100644 +index 28ba09319b047..92a52d2056b73 100644 --- extensions/browser/extension_host.h +++ extensions/browser/extension_host.h @@ -62,6 +62,12 @@ class ExtensionHost : public DeferredStartRenderHost, @@ -167,7 +167,7 @@ index 28ba09319b047..2a097a5ae4c16 100644 // The host for our HTML content. - std::unique_ptr host_contents_; + std::unique_ptr host_contents_owned_; -+ content::WebContents* host_contents_; ++ raw_ptr host_contents_; // A pointer to the current or speculative main frame in `host_contents_`. We // can't access this frame through the `host_contents_` directly as it does diff --git a/patch/patches/osr_fling_2745.patch b/patch/patches/osr_fling_2745.patch index ba793c8b8..82560b53f 100644 --- a/patch/patches/osr_fling_2745.patch +++ b/patch/patches/osr_fling_2745.patch @@ -41,11 +41,14 @@ index b3218a69a1d9e..a7b8e6c20659a 100644 RenderWidgetHostViewBase* GetRenderWidgetHostViewBase(); diff --git content/common/input/fling_scheduler_base.h content/common/input/fling_scheduler_base.h -index e8ee63f3abc2e..2d1717082759d 100644 +index e8ee63f3abc2e..765ea358e093a 100644 --- content/common/input/fling_scheduler_base.h +++ content/common/input/fling_scheduler_base.h -@@ -7,12 +7,23 @@ +@@ -5,14 +5,26 @@ + #ifndef CONTENT_COMMON_INPUT_FLING_SCHEDULER_BASE_H_ + #define CONTENT_COMMON_INPUT_FLING_SCHEDULER_BASE_H_ ++#include "base/memory/raw_ptr.h" #include "content/common/input/fling_controller.h" +namespace ui { @@ -64,7 +67,7 @@ index e8ee63f3abc2e..2d1717082759d 100644 + } + +protected: -+ ui::Compositor* compositor_ = nullptr; ++ raw_ptr compositor_ = nullptr; }; } // namespace content diff --git a/patch/patches/viz_osr_2575.patch b/patch/patches/viz_osr_2575.patch index dbce67bf3..190f9c4f3 100644 --- a/patch/patches/viz_osr_2575.patch +++ b/patch/patches/viz_osr_2575.patch @@ -223,7 +223,7 @@ index 2f462f0deb5fc..695869b83cefa 100644 + Draw(gfx.mojom.Rect damage_rect) => (); }; diff --git ui/compositor/compositor.h ui/compositor/compositor.h -index 9019859a51edf..ed88b61c6dd69 100644 +index 9019859a51edf..636dd2a822812 100644 --- ui/compositor/compositor.h +++ ui/compositor/compositor.h @@ -33,7 +33,9 @@ @@ -265,7 +265,7 @@ index 9019859a51edf..ed88b61c6dd69 100644 simple_begin_frame_observers_; std::unique_ptr host_begin_frame_observer_; -+ CompositorDelegate* delegate_ = nullptr; ++ raw_ptr delegate_ = nullptr; + // The root of the Layer tree drawn by this compositor. raw_ptr root_layer_ = nullptr;