mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Update to Chromium revision 5fdc0fab (#520840)
- Windows now builds with clang by default.
This commit is contained in:
27
patch/patches/DEPS.patch
Normal file
27
patch/patches/DEPS.patch
Normal file
@@ -0,0 +1,27 @@
|
||||
diff --git build/toolchain/win/rc/linux64/rc.sha1 build/toolchain/win/rc/linux64/rc.sha1
|
||||
index 76f7627..11440ae 100644
|
||||
--- build/toolchain/win/rc/linux64/rc.sha1
|
||||
+++ build/toolchain/win/rc/linux64/rc.sha1
|
||||
@@ -1 +1 @@
|
||||
-a6d75f015275c8a65ff855e8b78437dd03a9bb7d
|
||||
\ No newline at end of file
|
||||
+e642170ce663c75a44822c3bffb1579068ab6f17
|
||||
\ No newline at end of file
|
||||
diff --git build/toolchain/win/rc/mac/rc.sha1 build/toolchain/win/rc/mac/rc.sha1
|
||||
index 8a817c5..ff0c32e 100644
|
||||
--- build/toolchain/win/rc/mac/rc.sha1
|
||||
+++ build/toolchain/win/rc/mac/rc.sha1
|
||||
@@ -1 +1 @@
|
||||
-3ccc7a61fc5368e8db33364093e42a92de874a26
|
||||
\ No newline at end of file
|
||||
+58489426ecea29e276c94529201bc6a0cc1da027
|
||||
\ No newline at end of file
|
||||
diff --git build/toolchain/win/rc/win/rc.exe.sha1 build/toolchain/win/rc/win/rc.exe.sha1
|
||||
index c74dce41..165e4688 100644
|
||||
--- build/toolchain/win/rc/win/rc.exe.sha1
|
||||
+++ build/toolchain/win/rc/win/rc.exe.sha1
|
||||
@@ -1 +1 @@
|
||||
-9887dc07d042bf58d20b5557e3f91d18d0254022
|
||||
\ No newline at end of file
|
||||
+9de6c3d751b4432a3a7b1cf96f432a21187764e9
|
||||
\ No newline at end of file
|
52
patch/patches/blink_mojo_806477.patch
Normal file
52
patch/patches/blink_mojo_806477.patch
Normal file
@@ -0,0 +1,52 @@
|
||||
diff --git third_party/WebKit/Source/core/frame/Deprecation.cpp third_party/WebKit/Source/core/frame/Deprecation.cpp
|
||||
index db80f4a67b11..f3191313f929 100644
|
||||
--- third_party/WebKit/Source/core/frame/Deprecation.cpp
|
||||
+++ third_party/WebKit/Source/core/frame/Deprecation.cpp
|
||||
@@ -16,8 +16,9 @@
|
||||
#include "core/page/Page.h"
|
||||
#include "core/workers/WorkerOrWorkletGlobalScope.h"
|
||||
#include "platform/runtime_enabled_features.h"
|
||||
+#include "public/platform/Platform.h"
|
||||
#include "public/platform/reporting.mojom-blink.h"
|
||||
-#include "services/service_manager/public/cpp/interface_provider.h"
|
||||
+#include "services/service_manager/public/cpp/connector.h"
|
||||
#include "third_party/WebKit/common/feature_policy/feature_policy_feature.h"
|
||||
|
||||
using blink::WebFeature;
|
||||
@@ -796,7 +797,9 @@ void Deprecation::GenerateReport(const LocalFrame* frame, WebFeature feature) {
|
||||
|
||||
// Send the deprecation report to the Reporting API.
|
||||
mojom::blink::ReportingServiceProxyPtr service;
|
||||
- frame->Client()->GetInterfaceProvider()->GetInterface(&service);
|
||||
+ Platform* platform = Platform::Current();
|
||||
+ platform->GetConnector()->BindInterface(platform->GetBrowserServiceName(),
|
||||
+ &service);
|
||||
service->QueueDeprecationReport(document->Url(), info.message,
|
||||
body->sourceFile(), body->lineNumber(),
|
||||
body->columnNumber());
|
||||
diff --git third_party/WebKit/Source/core/frame/Intervention.cpp third_party/WebKit/Source/core/frame/Intervention.cpp
|
||||
index fb342ba765db..089eb6a3d662 100644
|
||||
--- third_party/WebKit/Source/core/frame/Intervention.cpp
|
||||
+++ third_party/WebKit/Source/core/frame/Intervention.cpp
|
||||
@@ -11,8 +11,9 @@
|
||||
#include "core/frame/Report.h"
|
||||
#include "core/frame/ReportingContext.h"
|
||||
#include "core/inspector/ConsoleMessage.h"
|
||||
+#include "public/platform/Platform.h"
|
||||
#include "public/platform/reporting.mojom-blink.h"
|
||||
-#include "services/service_manager/public/cpp/interface_provider.h"
|
||||
+#include "services/service_manager/public/cpp/connector.h"
|
||||
|
||||
namespace blink {
|
||||
|
||||
@@ -44,7 +45,9 @@ void Intervention::GenerateReport(const LocalFrame* frame,
|
||||
|
||||
// Send the intervention report to the Reporting API.
|
||||
mojom::blink::ReportingServiceProxyPtr service;
|
||||
- frame->Client()->GetInterfaceProvider()->GetInterface(&service);
|
||||
+ Platform* platform = Platform::Current();
|
||||
+ platform->GetConnector()->BindInterface(platform->GetBrowserServiceName(),
|
||||
+ &service);
|
||||
service->QueueInterventionReport(document->Url(), message, body->sourceFile(),
|
||||
body->lineNumber(), body->columnNumber());
|
||||
}
|
@@ -1,8 +1,8 @@
|
||||
diff --git content/browser/renderer_host/browser_compositor_view_mac.h content/browser/renderer_host/browser_compositor_view_mac.h
|
||||
index 8bc4ebd0d771..42949486cf98 100644
|
||||
index 3ed8b18dfabd..f0c30a60376a 100644
|
||||
--- content/browser/renderer_host/browser_compositor_view_mac.h
|
||||
+++ content/browser/renderer_host/browser_compositor_view_mac.h
|
||||
@@ -52,6 +52,7 @@ class CONTENT_EXPORT BrowserCompositorMac : public DelegatedFrameHostClient {
|
||||
@@ -53,6 +53,7 @@ class CONTENT_EXPORT BrowserCompositorMac : public DelegatedFrameHostClient {
|
||||
|
||||
// These will not return nullptr until Destroy is called.
|
||||
DelegatedFrameHost* GetDelegatedFrameHost();
|
||||
@@ -10,7 +10,7 @@ index 8bc4ebd0d771..42949486cf98 100644
|
||||
|
||||
// Ensure that the currect compositor frame be cleared (even if it is
|
||||
// potentially visible).
|
||||
@@ -59,6 +60,7 @@ class CONTENT_EXPORT BrowserCompositorMac : public DelegatedFrameHostClient {
|
||||
@@ -60,6 +61,7 @@ class CONTENT_EXPORT BrowserCompositorMac : public DelegatedFrameHostClient {
|
||||
|
||||
// This may return nullptr, if this has detached itself from its
|
||||
// ui::Compositor.
|
||||
@@ -19,10 +19,10 @@ index 8bc4ebd0d771..42949486cf98 100644
|
||||
|
||||
void DidCreateNewRendererCompositorFrameSink(
|
||||
diff --git content/browser/renderer_host/browser_compositor_view_mac.mm content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
index 04ca86589a13..796a874d0e13 100644
|
||||
index 00169dea145c..cb3d2b3175b1 100644
|
||||
--- content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
+++ content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
@@ -209,6 +209,12 @@ BrowserCompositorMac::~BrowserCompositorMac() {
|
||||
@@ -211,6 +211,12 @@ BrowserCompositorMac::~BrowserCompositorMac() {
|
||||
g_spare_recyclable_compositors.Get().clear();
|
||||
}
|
||||
|
||||
@@ -35,7 +35,7 @@ index 04ca86589a13..796a874d0e13 100644
|
||||
ui::AcceleratedWidgetMac* BrowserCompositorMac::GetAcceleratedWidgetMac() {
|
||||
if (recyclable_compositor_)
|
||||
return recyclable_compositor_->accelerated_widget_mac();
|
||||
@@ -439,8 +445,13 @@ SkColor BrowserCompositorMac::DelegatedFrameHostGetGutterColor(
|
||||
@@ -441,8 +447,13 @@ SkColor BrowserCompositorMac::DelegatedFrameHostGetGutterColor(
|
||||
}
|
||||
|
||||
gfx::Size BrowserCompositorMac::DelegatedFrameHostDesiredSizeInDIP() const {
|
||||
|
@@ -1,22 +0,0 @@
|
||||
diff --git content/browser/frame_host/render_widget_host_view_guest.cc content/browser/frame_host/render_widget_host_view_guest.cc
|
||||
index e885721017fd..7a20a016b389 100644
|
||||
--- content/browser/frame_host/render_widget_host_view_guest.cc
|
||||
+++ content/browser/frame_host/render_widget_host_view_guest.cc
|
||||
@@ -251,13 +251,14 @@ void RenderWidgetHostViewGuest::Destroy() {
|
||||
}
|
||||
|
||||
gfx::Size RenderWidgetHostViewGuest::GetPhysicalBackingSize() const {
|
||||
+ RenderWidgetHostViewBase* rwhv = GetOwnerRenderWidgetHostView();
|
||||
+ if (rwhv)
|
||||
+ return rwhv->GetPhysicalBackingSize();
|
||||
// We obtain the reference to native view from the owner RenderWidgetHostView.
|
||||
// If the guest is embedded inside a cross-process frame, it is possible to
|
||||
// reach here after the frame is detached in which case there will be no owner
|
||||
// view.
|
||||
- if (!GetOwnerRenderWidgetHostView())
|
||||
- return gfx::Size();
|
||||
- return RenderWidgetHostViewBase::GetPhysicalBackingSize();
|
||||
+ return gfx::Size();
|
||||
}
|
||||
|
||||
base::string16 RenderWidgetHostViewGuest::GetSelectedText() {
|
@@ -1,8 +1,8 @@
|
||||
diff --git content/browser/browser_plugin/browser_plugin_guest.cc content/browser/browser_plugin/browser_plugin_guest.cc
|
||||
index e6e79a68e263..c8007ccea445 100644
|
||||
index ccdafd2e9280..3d3651cf5b26 100644
|
||||
--- content/browser/browser_plugin/browser_plugin_guest.cc
|
||||
+++ content/browser/browser_plugin/browser_plugin_guest.cc
|
||||
@@ -337,8 +337,11 @@ void BrowserPluginGuest::InitInternal(
|
||||
@@ -339,8 +339,11 @@ void BrowserPluginGuest::InitInternal(
|
||||
static_cast<WebContentsViewGuest*>(GetWebContents()->GetView());
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@ index e6e79a68e263..c8007ccea445 100644
|
||||
|
||||
// Once a BrowserPluginGuest has an embedder WebContents, it's considered to
|
||||
// be attached.
|
||||
@@ -832,10 +835,19 @@ void BrowserPluginGuest::OnWillAttachComplete(
|
||||
@@ -837,10 +840,19 @@ void BrowserPluginGuest::OnWillAttachComplete(
|
||||
static_cast<WebContentsViewGuest*>(GetWebContents()->GetView());
|
||||
if (!web_contents()->GetRenderViewHost()->GetWidget()->GetView()) {
|
||||
web_contents_view->CreateViewForWidget(
|
||||
@@ -37,7 +37,7 @@ index e6e79a68e263..c8007ccea445 100644
|
||||
|
||||
attached_ = true;
|
||||
diff --git content/browser/frame_host/interstitial_page_impl.cc content/browser/frame_host/interstitial_page_impl.cc
|
||||
index 5db34c6d5f92..cdd9d1245571 100644
|
||||
index 2f24f1b959d4..5cfb0b3e97c6 100644
|
||||
--- content/browser/frame_host/interstitial_page_impl.cc
|
||||
+++ content/browser/frame_host/interstitial_page_impl.cc
|
||||
@@ -613,7 +613,7 @@ WebContentsView* InterstitialPageImpl::CreateWebContentsView() {
|
||||
@@ -50,7 +50,7 @@ index 5db34c6d5f92..cdd9d1245571 100644
|
||||
render_view_host_->GetMainFrame()->AllowBindings(
|
||||
BINDINGS_POLICY_DOM_AUTOMATION);
|
||||
diff --git content/browser/web_contents/web_contents_view.h content/browser/web_contents/web_contents_view.h
|
||||
index e4401f85bf3f..20b85609a23f 100644
|
||||
index a38a936af6df..5380e09ee023 100644
|
||||
--- content/browser/web_contents/web_contents_view.h
|
||||
+++ content/browser/web_contents/web_contents_view.h
|
||||
@@ -24,7 +24,7 @@ struct ScreenInfo;
|
||||
@@ -62,7 +62,7 @@ index e4401f85bf3f..20b85609a23f 100644
|
||||
public:
|
||||
virtual ~WebContentsView() {}
|
||||
|
||||
@@ -86,13 +86,9 @@ class WebContentsView {
|
||||
@@ -91,13 +91,9 @@ class WebContentsView {
|
||||
// Sets up the View that holds the rendered web page, receives messages for
|
||||
// it and contains page plugins. The host view should be sized to the current
|
||||
// size of the WebContents.
|
||||
@@ -79,10 +79,10 @@ index e4401f85bf3f..20b85609a23f 100644
|
||||
// Creates a new View that holds a popup and receives messages for it.
|
||||
virtual RenderWidgetHostViewBase* CreateViewForPopupWidget(
|
||||
diff --git content/browser/web_contents/web_contents_view_aura.cc content/browser/web_contents/web_contents_view_aura.cc
|
||||
index 3395028a568b..5364563c606b 100644
|
||||
index ee18b4dd66bd..9e447f7d9511 100644
|
||||
--- content/browser/web_contents/web_contents_view_aura.cc
|
||||
+++ content/browser/web_contents/web_contents_view_aura.cc
|
||||
@@ -840,7 +840,8 @@ void WebContentsViewAura::CreateView(
|
||||
@@ -886,7 +886,8 @@ void WebContentsViewAura::CreateView(const gfx::Size& initial_size,
|
||||
}
|
||||
|
||||
RenderWidgetHostViewBase* WebContentsViewAura::CreateViewForWidget(
|
||||
@@ -92,7 +92,7 @@ index 3395028a568b..5364563c606b 100644
|
||||
if (render_widget_host->GetView()) {
|
||||
// During testing, the view will already be set up in most cases to the
|
||||
// test view, so we don't want to clobber it with a real one. To verify that
|
||||
@@ -852,6 +853,7 @@ RenderWidgetHostViewBase* WebContentsViewAura::CreateViewForWidget(
|
||||
@@ -898,6 +899,7 @@ RenderWidgetHostViewBase* WebContentsViewAura::CreateViewForWidget(
|
||||
render_widget_host->GetView());
|
||||
}
|
||||
|
||||
@@ -101,10 +101,10 @@ index 3395028a568b..5364563c606b 100644
|
||||
g_create_render_widget_host_view
|
||||
? g_create_render_widget_host_view(render_widget_host,
|
||||
diff --git content/browser/web_contents/web_contents_view_aura.h content/browser/web_contents/web_contents_view_aura.h
|
||||
index 359032e66343..b45b8c426421 100644
|
||||
index 7b2078f53dc4..e65fd914dd0d 100644
|
||||
--- content/browser/web_contents/web_contents_view_aura.h
|
||||
+++ content/browser/web_contents/web_contents_view_aura.h
|
||||
@@ -116,7 +116,7 @@ class CONTENT_EXPORT WebContentsViewAura
|
||||
@@ -120,7 +120,7 @@ class CONTENT_EXPORT WebContentsViewAura
|
||||
gfx::NativeView context) override;
|
||||
RenderWidgetHostViewBase* CreateViewForWidget(
|
||||
RenderWidgetHost* render_widget_host,
|
||||
@@ -114,10 +114,10 @@ index 359032e66343..b45b8c426421 100644
|
||||
RenderWidgetHost* render_widget_host) override;
|
||||
void SetPageTitle(const base::string16& title) override;
|
||||
diff --git content/browser/web_contents/web_contents_view_child_frame.cc content/browser/web_contents/web_contents_view_child_frame.cc
|
||||
index e1aca335ede0..47e02fc73f74 100644
|
||||
index e1db175c25cb..1ef7b20a7add 100644
|
||||
--- content/browser/web_contents/web_contents_view_child_frame.cc
|
||||
+++ content/browser/web_contents/web_contents_view_child_frame.cc
|
||||
@@ -94,7 +94,7 @@ void WebContentsViewChildFrame::CreateView(const gfx::Size& initial_size,
|
||||
@@ -96,7 +96,7 @@ void WebContentsViewChildFrame::CreateView(const gfx::Size& initial_size,
|
||||
|
||||
RenderWidgetHostViewBase* WebContentsViewChildFrame::CreateViewForWidget(
|
||||
RenderWidgetHost* render_widget_host,
|
||||
@@ -127,10 +127,10 @@ index e1aca335ede0..47e02fc73f74 100644
|
||||
}
|
||||
|
||||
diff --git content/browser/web_contents/web_contents_view_child_frame.h content/browser/web_contents/web_contents_view_child_frame.h
|
||||
index 18d45eea524f..6aa738daf5b5 100644
|
||||
index ca3c586f9f8f..5fd0e860a5ff 100644
|
||||
--- content/browser/web_contents/web_contents_view_child_frame.h
|
||||
+++ content/browser/web_contents/web_contents_view_child_frame.h
|
||||
@@ -40,7 +40,7 @@ class WebContentsViewChildFrame : public WebContentsView,
|
||||
@@ -41,7 +41,7 @@ class WebContentsViewChildFrame : public WebContentsView,
|
||||
gfx::NativeView context) override;
|
||||
RenderWidgetHostViewBase* CreateViewForWidget(
|
||||
RenderWidgetHost* render_widget_host,
|
||||
@@ -140,10 +140,10 @@ index 18d45eea524f..6aa738daf5b5 100644
|
||||
RenderWidgetHost* render_widget_host) override;
|
||||
void SetPageTitle(const base::string16& title) override;
|
||||
diff --git content/browser/web_contents/web_contents_view_guest.cc content/browser/web_contents/web_contents_view_guest.cc
|
||||
index 025686922ade..da7a9b88cabc 100644
|
||||
index f1370d294ef9..d7a451028e64 100644
|
||||
--- content/browser/web_contents/web_contents_view_guest.cc
|
||||
+++ content/browser/web_contents/web_contents_view_guest.cc
|
||||
@@ -72,6 +72,8 @@ void WebContentsViewGuest::GetScreenInfo(ScreenInfo* screen_info) const {
|
||||
@@ -73,6 +73,8 @@ void WebContentsViewGuest::GetScreenInfo(ScreenInfo* screen_info) const {
|
||||
|
||||
void WebContentsViewGuest::OnGuestAttached(WebContentsView* parent_view) {
|
||||
#if defined(USE_AURA)
|
||||
@@ -152,16 +152,16 @@ index 025686922ade..da7a9b88cabc 100644
|
||||
// In aura, ScreenPositionClient doesn't work properly if we do
|
||||
// not have the native view associated with this WebContentsViewGuest in the
|
||||
// view hierarchy. We add this view as embedder's child here.
|
||||
@@ -83,6 +85,8 @@ void WebContentsViewGuest::OnGuestAttached(WebContentsView* parent_view) {
|
||||
@@ -85,6 +87,8 @@ void WebContentsViewGuest::OnGuestAttached(WebContentsView* parent_view) {
|
||||
|
||||
void WebContentsViewGuest::OnGuestDetached(WebContentsView* old_parent_view) {
|
||||
#if defined(USE_AURA)
|
||||
+ if (!platform_view_->GetNativeView())
|
||||
+ return;
|
||||
old_parent_view->GetNativeView()->RemoveChild(
|
||||
platform_view_->GetNativeView());
|
||||
#endif // defined(USE_AURA)
|
||||
@@ -134,7 +138,8 @@ void WebContentsViewGuest::CreateView(const gfx::Size& initial_size,
|
||||
if (!IsUsingMus()) {
|
||||
old_parent_view->GetNativeView()->RemoveChild(
|
||||
platform_view_->GetNativeView());
|
||||
@@ -138,7 +142,8 @@ void WebContentsViewGuest::CreateView(const gfx::Size& initial_size,
|
||||
}
|
||||
|
||||
RenderWidgetHostViewBase* WebContentsViewGuest::CreateViewForWidget(
|
||||
@@ -171,7 +171,7 @@ index 025686922ade..da7a9b88cabc 100644
|
||||
if (render_widget_host->GetView()) {
|
||||
// During testing, the view will already be set up in most cases to the
|
||||
// test view, so we don't want to clobber it with a real one. To verify that
|
||||
@@ -146,11 +151,19 @@ RenderWidgetHostViewBase* WebContentsViewGuest::CreateViewForWidget(
|
||||
@@ -150,11 +155,19 @@ RenderWidgetHostViewBase* WebContentsViewGuest::CreateViewForWidget(
|
||||
render_widget_host->GetView());
|
||||
}
|
||||
|
||||
@@ -195,10 +195,10 @@ index 025686922ade..da7a9b88cabc 100644
|
||||
|
||||
RenderWidgetHostViewBase* WebContentsViewGuest::CreateViewForPopupWidget(
|
||||
diff --git content/browser/web_contents/web_contents_view_guest.h content/browser/web_contents/web_contents_view_guest.h
|
||||
index 464ea8f780e4..0d3118df538a 100644
|
||||
index c04fe9bc23c4..5dba7a8b9e76 100644
|
||||
--- content/browser/web_contents/web_contents_view_guest.h
|
||||
+++ content/browser/web_contents/web_contents_view_guest.h
|
||||
@@ -58,7 +58,7 @@ class WebContentsViewGuest : public WebContentsView,
|
||||
@@ -59,7 +59,7 @@ class WebContentsViewGuest : public WebContentsView,
|
||||
gfx::NativeView context) override;
|
||||
RenderWidgetHostViewBase* CreateViewForWidget(
|
||||
RenderWidgetHost* render_widget_host,
|
||||
@@ -208,7 +208,7 @@ index 464ea8f780e4..0d3118df538a 100644
|
||||
RenderWidgetHost* render_widget_host) override;
|
||||
void SetPageTitle(const base::string16& title) override;
|
||||
diff --git content/browser/web_contents/web_contents_view_mac.h content/browser/web_contents/web_contents_view_mac.h
|
||||
index 12675d077c8a..46db5596618e 100644
|
||||
index 95ba5f05e4f7..39d4d764136c 100644
|
||||
--- content/browser/web_contents/web_contents_view_mac.h
|
||||
+++ content/browser/web_contents/web_contents_view_mac.h
|
||||
@@ -90,7 +90,7 @@ class WebContentsViewMac : public WebContentsView,
|
||||
@@ -221,10 +221,10 @@ index 12675d077c8a..46db5596618e 100644
|
||||
RenderWidgetHost* render_widget_host) override;
|
||||
void SetPageTitle(const base::string16& title) override;
|
||||
diff --git content/browser/web_contents/web_contents_view_mac.mm content/browser/web_contents/web_contents_view_mac.mm
|
||||
index abcbb302f417..63e73721f155 100644
|
||||
index 2c5dd9e99e6d..39d6bceb55ed 100644
|
||||
--- content/browser/web_contents/web_contents_view_mac.mm
|
||||
+++ content/browser/web_contents/web_contents_view_mac.mm
|
||||
@@ -353,7 +353,8 @@ void WebContentsViewMac::CreateView(
|
||||
@@ -376,7 +376,8 @@ void WebContentsViewMac::CreateView(
|
||||
}
|
||||
|
||||
RenderWidgetHostViewBase* WebContentsViewMac::CreateViewForWidget(
|
||||
@@ -234,7 +234,7 @@ index abcbb302f417..63e73721f155 100644
|
||||
if (render_widget_host->GetView()) {
|
||||
// During testing, the view will already be set up in most cases to the
|
||||
// test view, so we don't want to clobber it with a real one. To verify that
|
||||
@@ -365,6 +366,7 @@ RenderWidgetHostViewBase* WebContentsViewMac::CreateViewForWidget(
|
||||
@@ -388,6 +389,7 @@ RenderWidgetHostViewBase* WebContentsViewMac::CreateViewForWidget(
|
||||
render_widget_host->GetView());
|
||||
}
|
||||
|
||||
@@ -243,7 +243,7 @@ index abcbb302f417..63e73721f155 100644
|
||||
g_create_render_widget_host_view
|
||||
? g_create_render_widget_host_view(render_widget_host,
|
||||
diff --git content/public/browser/browser_plugin_guest_delegate.h content/public/browser/browser_plugin_guest_delegate.h
|
||||
index ef0ff9d6f67b..4eab513ba4ce 100644
|
||||
index 9a3c2375c7f6..f95ea9cbe9ba 100644
|
||||
--- content/public/browser/browser_plugin_guest_delegate.h
|
||||
+++ content/public/browser/browser_plugin_guest_delegate.h
|
||||
@@ -19,6 +19,7 @@ namespace content {
|
||||
@@ -254,7 +254,7 @@ index ef0ff9d6f67b..4eab513ba4ce 100644
|
||||
|
||||
// Objects implement this interface to get notified about changes in the guest
|
||||
// WebContents and to provide necessary functionality.
|
||||
@@ -72,6 +73,10 @@ class CONTENT_EXPORT BrowserPluginGuestDelegate {
|
||||
@@ -67,6 +68,10 @@ class CONTENT_EXPORT BrowserPluginGuestDelegate {
|
||||
// content module.
|
||||
virtual void SetGuestHost(GuestHost* guest_host) {}
|
||||
|
||||
|
31
patch/patches/chrome_browser.patch
Normal file
31
patch/patches/chrome_browser.patch
Normal file
@@ -0,0 +1,31 @@
|
||||
diff --git chrome/browser/BUILD.gn chrome/browser/BUILD.gn
|
||||
index 1126d7e63c30..64ecb8982428 100644
|
||||
--- chrome/browser/BUILD.gn
|
||||
+++ chrome/browser/BUILD.gn
|
||||
@@ -7,6 +7,7 @@ import("//build/config/crypto.gni")
|
||||
import("//build/config/features.gni")
|
||||
import("//build/config/ui.gni")
|
||||
import("//build/split_static_library.gni")
|
||||
+import("//cef/libcef/features/features.gni")
|
||||
import("//chrome/common/features.gni")
|
||||
import("//components/feature_engagement/features.gni")
|
||||
import("//components/nacl/features.gni")
|
||||
@@ -1551,6 +1552,7 @@ split_static_library("browser") {
|
||||
"//base:i18n",
|
||||
"//base/allocator:features",
|
||||
"//cc",
|
||||
+ "//cef/libcef/features",
|
||||
"//chrome:extra_resources",
|
||||
"//chrome:resources",
|
||||
"//chrome:strings",
|
||||
@@ -1797,6 +1799,10 @@ split_static_library("browser") {
|
||||
"//ui/web_dialogs",
|
||||
]
|
||||
|
||||
+ if (enable_cef) {
|
||||
+ configs += [ "//cef/libcef/features:config" ]
|
||||
+ }
|
||||
+
|
||||
if (is_android) {
|
||||
sources += [
|
||||
"after_startup_task_utils_android.cc",
|
@@ -1,11 +1,12 @@
|
||||
diff --git chrome/browser/profiles/incognito_helpers.cc chrome/browser/profiles/incognito_helpers.cc
|
||||
index 6155e9606d67..2125a436c87e 100644
|
||||
index ce4f72b98a05..f7d57b854399 100644
|
||||
--- chrome/browser/profiles/incognito_helpers.cc
|
||||
+++ chrome/browser/profiles/incognito_helpers.cc
|
||||
@@ -8,13 +8,35 @@
|
||||
@@ -7,19 +7,42 @@
|
||||
#include "chrome/browser/profiles/profile.h"
|
||||
|
||||
namespace chrome {
|
||||
|
||||
+
|
||||
+namespace {
|
||||
+BrowserContextIncognitoHelper* g_helper = nullptr;
|
||||
+} // namespace
|
||||
@@ -13,7 +14,7 @@ index 6155e9606d67..2125a436c87e 100644
|
||||
+void SetBrowserContextIncognitoHelper(BrowserContextIncognitoHelper* helper) {
|
||||
+ g_helper = helper;
|
||||
+}
|
||||
+
|
||||
|
||||
content::BrowserContext* GetBrowserContextRedirectedInIncognito(
|
||||
content::BrowserContext* context) {
|
||||
+ if (g_helper) {
|
||||
@@ -26,6 +27,13 @@ index 6155e9606d67..2125a436c87e 100644
|
||||
return static_cast<Profile*>(context)->GetOriginalProfile();
|
||||
}
|
||||
|
||||
const content::BrowserContext* GetBrowserContextRedirectedInIncognito(
|
||||
const content::BrowserContext* context) {
|
||||
- return static_cast<const Profile*>(context)->GetOriginalProfile();
|
||||
+ return GetBrowserContextRedirectedInIncognito(
|
||||
+ const_cast<content::BrowserContext*>(context));
|
||||
}
|
||||
|
||||
content::BrowserContext* GetBrowserContextOwnInstanceInIncognito(
|
||||
content::BrowserContext* context) {
|
||||
+ if (g_helper) {
|
||||
@@ -39,7 +47,7 @@ index 6155e9606d67..2125a436c87e 100644
|
||||
}
|
||||
|
||||
diff --git chrome/browser/profiles/incognito_helpers.h chrome/browser/profiles/incognito_helpers.h
|
||||
index 4b430133e16f..169ca4765907 100644
|
||||
index e8e76ce5b954..1dd338dd0142 100644
|
||||
--- chrome/browser/profiles/incognito_helpers.h
|
||||
+++ chrome/browser/profiles/incognito_helpers.h
|
||||
@@ -11,6 +11,19 @@ class BrowserContext;
|
||||
@@ -63,7 +71,7 @@ index 4b430133e16f..169ca4765907 100644
|
||||
content::BrowserContext* GetBrowserContextRedirectedInIncognito(
|
||||
content::BrowserContext* context);
|
||||
diff --git chrome/browser/profiles/profile_manager.cc chrome/browser/profiles/profile_manager.cc
|
||||
index a711472a63a9..47212b151d41 100644
|
||||
index 0fe78f76aaa7..8fb527cc2636 100644
|
||||
--- chrome/browser/profiles/profile_manager.cc
|
||||
+++ chrome/browser/profiles/profile_manager.cc
|
||||
@@ -375,7 +375,7 @@ ProfileManager::ProfileManager(const base::FilePath& user_data_dir)
|
189
patch/patches/chrome_plugins.patch
Normal file
189
patch/patches/chrome_plugins.patch
Normal file
@@ -0,0 +1,189 @@
|
||||
diff --git chrome/browser/plugins/plugin_info_host_impl.cc chrome/browser/plugins/plugin_info_host_impl.cc
|
||||
index 1afbaf86ac40..e2edec854ca7 100644
|
||||
--- chrome/browser/plugins/plugin_info_host_impl.cc
|
||||
+++ chrome/browser/plugins/plugin_info_host_impl.cc
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "base/task_runner_util.h"
|
||||
#include "base/threading/thread_task_runner_handle.h"
|
||||
#include "build/build_config.h"
|
||||
+#include "cef/libcef/features/features.h"
|
||||
#include "chrome/browser/browser_process.h"
|
||||
#include "chrome/browser/content_settings/host_content_settings_map_factory.h"
|
||||
#include "chrome/browser/plugins/chrome_plugin_service_filter.h"
|
||||
@@ -56,6 +57,11 @@
|
||||
#include "url/origin.h"
|
||||
#include "widevine_cdm_version.h" // In SHARED_INTERMEDIATE_DIR.
|
||||
|
||||
+#if BUILDFLAG(ENABLE_CEF)
|
||||
+#include "cef/libcef/browser/plugins/plugin_service_filter.h"
|
||||
+#include "cef/libcef/common/extensions/extensions_util.h"
|
||||
+#endif
|
||||
+
|
||||
#if BUILDFLAG(ENABLE_EXTENSIONS)
|
||||
#include "components/guest_view/browser/guest_view_base.h"
|
||||
#include "extensions/browser/extension_registry.h"
|
||||
@@ -77,12 +83,10 @@ namespace {
|
||||
class ShutdownNotifierFactory
|
||||
: public BrowserContextKeyedServiceShutdownNotifierFactory {
|
||||
public:
|
||||
- static ShutdownNotifierFactory* GetInstance() {
|
||||
- return base::Singleton<ShutdownNotifierFactory>::get();
|
||||
- }
|
||||
+ static ShutdownNotifierFactory* GetInstance();
|
||||
|
||||
private:
|
||||
- friend struct base::DefaultSingletonTraits<ShutdownNotifierFactory>;
|
||||
+ friend struct base::LazyInstanceTraitsBase<ShutdownNotifierFactory>;
|
||||
|
||||
ShutdownNotifierFactory()
|
||||
: BrowserContextKeyedServiceShutdownNotifierFactory(
|
||||
@@ -93,6 +97,14 @@ class ShutdownNotifierFactory
|
||||
DISALLOW_COPY_AND_ASSIGN(ShutdownNotifierFactory);
|
||||
};
|
||||
|
||||
+base::LazyInstance<ShutdownNotifierFactory>::Leaky g_shutdown_notifier_factory =
|
||||
+ LAZY_INSTANCE_INITIALIZER;
|
||||
+
|
||||
+// static
|
||||
+ShutdownNotifierFactory* ShutdownNotifierFactory::GetInstance() {
|
||||
+ return g_shutdown_notifier_factory.Pointer();
|
||||
+}
|
||||
+
|
||||
#if BUILDFLAG(ENABLE_LIBRARY_CDMS)
|
||||
|
||||
enum PluginAvailabilityStatusForUMA {
|
||||
@@ -124,6 +136,9 @@ bool IsPluginLoadingAccessibleResourceInWebView(
|
||||
extensions::ExtensionRegistry* extension_registry,
|
||||
int process_id,
|
||||
const GURL& resource) {
|
||||
+ if (!extension_registry)
|
||||
+ return false;
|
||||
+
|
||||
extensions::WebViewRendererState* renderer_state =
|
||||
extensions::WebViewRendererState::GetInstance();
|
||||
std::string partition_id;
|
||||
@@ -153,12 +168,16 @@ bool IsPluginLoadingAccessibleResourceInWebView(
|
||||
PluginInfoHostImpl::Context::Context(int render_process_id, Profile* profile)
|
||||
: render_process_id_(render_process_id),
|
||||
resource_context_(profile->GetResourceContext()),
|
||||
-#if BUILDFLAG(ENABLE_EXTENSIONS)
|
||||
- extension_registry_(extensions::ExtensionRegistry::Get(profile)),
|
||||
-#endif
|
||||
host_content_settings_map_(
|
||||
HostContentSettingsMapFactory::GetForProfile(profile)),
|
||||
plugin_prefs_(PluginPrefs::GetForProfile(profile)) {
|
||||
+#if BUILDFLAG(ENABLE_EXTENSIONS)
|
||||
+#if BUILDFLAG(ENABLE_CEF)
|
||||
+ if (extensions::ExtensionsEnabled())
|
||||
+#endif
|
||||
+ extension_registry_ = extensions::ExtensionRegistry::Get(profile);
|
||||
+#endif
|
||||
+
|
||||
allow_outdated_plugins_.Init(prefs::kPluginsAllowOutdated,
|
||||
profile->GetPrefs());
|
||||
allow_outdated_plugins_.MoveToThread(
|
||||
@@ -325,6 +344,14 @@ void PluginInfoHostImpl::Context::DecidePluginStatus(
|
||||
PluginMetadata::SecurityStatus security_status,
|
||||
const std::string& plugin_identifier,
|
||||
chrome::mojom::PluginStatus* status) const {
|
||||
+#if BUILDFLAG(ENABLE_CEF)
|
||||
+ // Don't override the user decision.
|
||||
+ if (*status == chrome::mojom::PluginStatus::kBlocked ||
|
||||
+ *status == chrome::mojom::PluginStatus::kDisabled) {
|
||||
+ return;
|
||||
+ }
|
||||
+#endif
|
||||
+
|
||||
if (security_status == PluginMetadata::SECURITY_STATUS_FULLY_TRUSTED) {
|
||||
*status = chrome::mojom::PluginStatus::kAllowed;
|
||||
return;
|
||||
@@ -450,16 +477,36 @@ bool PluginInfoHostImpl::Context::FindEnabledPlugin(
|
||||
return false;
|
||||
}
|
||||
|
||||
+ const bool is_main_frame =
|
||||
+ main_frame_origin.IsSameOriginWith(url::Origin::Create(url));
|
||||
+
|
||||
+#if BUILDFLAG(ENABLE_CEF)
|
||||
+ CefPluginServiceFilter* filter = static_cast<CefPluginServiceFilter*>(
|
||||
+ PluginService::GetInstance()->GetFilter());
|
||||
+ DCHECK(filter);
|
||||
+
|
||||
+ size_t i = 0;
|
||||
+ for (; i < matching_plugins.size(); ++i) {
|
||||
+ if (filter->IsPluginAvailable(render_process_id_, render_frame_id,
|
||||
+ resource_context_, url, is_main_frame,
|
||||
+ main_frame_origin, &matching_plugins[i],
|
||||
+ status)) {
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
+#else // !BUILDFLAG(ENABLE_CEF)
|
||||
content::PluginServiceFilter* filter =
|
||||
PluginService::GetInstance()->GetFilter();
|
||||
size_t i = 0;
|
||||
for (; i < matching_plugins.size(); ++i) {
|
||||
if (!filter || filter->IsPluginAvailable(
|
||||
render_process_id_, render_frame_id, resource_context_,
|
||||
- url, main_frame_origin, &matching_plugins[i])) {
|
||||
+ url, is_main_frame, main_frame_origin,
|
||||
+ &matching_plugins[i])) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
+#endif // !BUILDFLAG(ENABLE_CEF)
|
||||
|
||||
// If we broke out of the loop, we have found an enabled plugin.
|
||||
bool enabled = i < matching_plugins.size();
|
||||
diff --git chrome/renderer/chrome_content_renderer_client.cc chrome/renderer/chrome_content_renderer_client.cc
|
||||
index 5dc888bfb2df..297737be682e 100644
|
||||
--- chrome/renderer/chrome_content_renderer_client.cc
|
||||
+++ chrome/renderer/chrome_content_renderer_client.cc
|
||||
@@ -805,6 +805,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
|
||||
|
||||
if ((status == chrome::mojom::PluginStatus::kUnauthorized ||
|
||||
status == chrome::mojom::PluginStatus::kBlocked) &&
|
||||
+ observer &&
|
||||
observer->IsPluginTemporarilyAllowed(identifier)) {
|
||||
status = chrome::mojom::PluginStatus::kAllowed;
|
||||
}
|
||||
@@ -992,7 +993,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
|
||||
render_frame->GetRemoteAssociatedInterfaces()->GetInterface(
|
||||
&plugin_auth_host);
|
||||
plugin_auth_host->BlockedUnauthorizedPlugin(group_name, identifier);
|
||||
- observer->DidBlockContentType(content_type, group_name);
|
||||
+ if (observer)
|
||||
+ observer->DidBlockContentType(content_type, group_name);
|
||||
break;
|
||||
}
|
||||
case chrome::mojom::PluginStatus::kBlocked: {
|
||||
@@ -1001,7 +1003,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
|
||||
l10n_util::GetStringFUTF16(IDS_PLUGIN_BLOCKED, group_name));
|
||||
placeholder->AllowLoading();
|
||||
RenderThread::Get()->RecordAction(UserMetricsAction("Plugin_Blocked"));
|
||||
- observer->DidBlockContentType(content_type, group_name);
|
||||
+ if (observer)
|
||||
+ observer->DidBlockContentType(content_type, group_name);
|
||||
break;
|
||||
}
|
||||
case chrome::mojom::PluginStatus::kBlockedByPolicy: {
|
||||
@@ -1011,7 +1014,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
|
||||
group_name));
|
||||
RenderThread::Get()->RecordAction(
|
||||
UserMetricsAction("Plugin_BlockedByPolicy"));
|
||||
- observer->DidBlockContentType(content_type, group_name);
|
||||
+ if (observer)
|
||||
+ observer->DidBlockContentType(content_type, group_name);
|
||||
break;
|
||||
}
|
||||
case chrome::mojom::PluginStatus::kBlockedNoLoading: {
|
||||
@@ -1019,7 +1023,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
|
||||
IDR_BLOCKED_PLUGIN_HTML,
|
||||
l10n_util::GetStringFUTF16(IDS_PLUGIN_BLOCKED_NO_LOADING,
|
||||
group_name));
|
||||
- observer->DidBlockContentType(content_type, group_name);
|
||||
+ if (observer)
|
||||
+ observer->DidBlockContentType(content_type, group_name);
|
||||
break;
|
||||
}
|
||||
case chrome::mojom::PluginStatus::kComponentUpdateRequired: {
|
31
patch/patches/chrome_renderer.patch
Normal file
31
patch/patches/chrome_renderer.patch
Normal file
@@ -0,0 +1,31 @@
|
||||
diff --git chrome/renderer/BUILD.gn chrome/renderer/BUILD.gn
|
||||
index da3b9d31a05b..78c15d30755d 100644
|
||||
--- chrome/renderer/BUILD.gn
|
||||
+++ chrome/renderer/BUILD.gn
|
||||
@@ -3,6 +3,7 @@
|
||||
# found in the LICENSE file.
|
||||
|
||||
import("//build/config/features.gni")
|
||||
+import("//cef/libcef/features/features.gni")
|
||||
import("//chrome/common/features.gni")
|
||||
import("//components/nacl/features.gni")
|
||||
import("//components/spellcheck/spellcheck_build_features.gni")
|
||||
@@ -102,6 +103,7 @@ static_library("renderer") {
|
||||
defines = []
|
||||
|
||||
deps = [
|
||||
+ "//cef/libcef/features",
|
||||
"//chrome:resources",
|
||||
"//chrome:strings",
|
||||
"//chrome/common",
|
||||
@@ -161,6 +163,10 @@ static_library("renderer") {
|
||||
|
||||
configs += [ "//build/config/compiler:wexit_time_destructors" ]
|
||||
|
||||
+ if (enable_cef) {
|
||||
+ configs += [ "//cef/libcef/features:config" ]
|
||||
+ }
|
||||
+
|
||||
if (enable_nacl) {
|
||||
deps += [
|
||||
"//components/nacl/loader",
|
@@ -1,5 +1,5 @@
|
||||
diff --git chrome/common/chrome_content_client.cc chrome/common/chrome_content_client.cc
|
||||
index 84016e8ad769..684b9d1f6089 100644
|
||||
index 8171be4d4249..1d437dabd35e 100644
|
||||
--- chrome/common/chrome_content_client.cc
|
||||
+++ chrome/common/chrome_content_client.cc
|
||||
@@ -90,7 +90,8 @@
|
||||
|
@@ -1,17 +1,5 @@
|
||||
diff --git chrome/browser/ui/BUILD.gn chrome/browser/ui/BUILD.gn
|
||||
index 82f43b9591ae..1ef9adad166f 100644
|
||||
--- chrome/browser/ui/BUILD.gn
|
||||
+++ chrome/browser/ui/BUILD.gn
|
||||
@@ -369,6 +369,7 @@ split_static_library("ui") {
|
||||
"//chrome/browser/ui/webui/usb_internals:mojo_bindings",
|
||||
"//chrome/common",
|
||||
"//chrome/common:search_mojom",
|
||||
+ "//chrome/common:service_process_mojom",
|
||||
"//chrome/common/net",
|
||||
"//chrome/installer/util:with_no_strings",
|
||||
"//components/about_ui",
|
||||
diff --git content/app/content_service_manager_main_delegate.h content/app/content_service_manager_main_delegate.h
|
||||
index 7563ce48bf5e..6c594749d57b 100644
|
||||
index 4393a8fac233..860715e86900 100644
|
||||
--- content/app/content_service_manager_main_delegate.h
|
||||
+++ content/app/content_service_manager_main_delegate.h
|
||||
@@ -16,7 +16,8 @@ namespace content {
|
||||
@@ -25,7 +13,7 @@ index 7563ce48bf5e..6c594749d57b 100644
|
||||
explicit ContentServiceManagerMainDelegate(const ContentMainParams& params);
|
||||
~ContentServiceManagerMainDelegate() override;
|
||||
diff --git third_party/WebKit/Source/controller/BUILD.gn third_party/WebKit/Source/controller/BUILD.gn
|
||||
index 1d29633ba10d..1a42fe1d37fa 100644
|
||||
index 714113da5d67..08130f97b76c 100644
|
||||
--- third_party/WebKit/Source/controller/BUILD.gn
|
||||
+++ third_party/WebKit/Source/controller/BUILD.gn
|
||||
@@ -16,6 +16,7 @@ component("controller") {
|
||||
|
@@ -1,23 +1,30 @@
|
||||
diff --git content/browser/compositor/gpu_process_transport_factory.cc content/browser/compositor/gpu_process_transport_factory.cc
|
||||
index 45bf6b1b4618..f41d40a6887b 100644
|
||||
index cddd17ca8682..c8641e9d0fdc 100644
|
||||
--- content/browser/compositor/gpu_process_transport_factory.cc
|
||||
+++ content/browser/compositor/gpu_process_transport_factory.cc
|
||||
@@ -274,6 +274,13 @@ GpuProcessTransportFactory::~GpuProcessTransportFactory() {
|
||||
std::unique_ptr<viz::SoftwareOutputDevice>
|
||||
GpuProcessTransportFactory::CreateSoftwareOutputDevice(
|
||||
ui::Compositor* compositor) {
|
||||
+ if (compositor->delegate()) {
|
||||
+ std::unique_ptr<viz::SoftwareOutputDevice> output_device =
|
||||
+ compositor->delegate()->CreateSoftwareOutputDevice(compositor);
|
||||
+ if (output_device)
|
||||
+ return output_device;
|
||||
+ }
|
||||
@@ -502,9 +502,19 @@ void GpuProcessTransportFactory::EstablishedGpuChannel(
|
||||
// surfaces as they are not following the correct mode.
|
||||
DisableGpuCompositing(compositor.get());
|
||||
}
|
||||
+
|
||||
base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
|
||||
if (command_line->HasSwitch(switches::kHeadless))
|
||||
return base::WrapUnique(new viz::SoftwareOutputDevice);
|
||||
+ std::unique_ptr<viz::SoftwareOutputDevice> output_device;
|
||||
+ if (compositor->delegate()) {
|
||||
+ output_device = compositor->delegate()->CreateSoftwareOutputDevice(
|
||||
+ compositor.get());
|
||||
+ }
|
||||
+ if (!output_device) {
|
||||
+ output_device = CreateSoftwareOutputDevice(compositor->widget());
|
||||
+ }
|
||||
+
|
||||
display_output_surface =
|
||||
std::make_unique<SoftwareBrowserCompositorOutputSurface>(
|
||||
- CreateSoftwareOutputDevice(compositor->widget()), vsync_callback,
|
||||
+ std::move(output_device), vsync_callback,
|
||||
compositor->task_runner());
|
||||
} else {
|
||||
DCHECK(context_provider);
|
||||
diff --git ui/compositor/compositor.h ui/compositor/compositor.h
|
||||
index d842aa55175b..5683e6fb68f8 100644
|
||||
index 00885cbac420..874ec42e3825 100644
|
||||
--- ui/compositor/compositor.h
|
||||
+++ ui/compositor/compositor.h
|
||||
@@ -23,6 +23,7 @@
|
||||
@@ -46,7 +53,7 @@ index d842aa55175b..5683e6fb68f8 100644
|
||||
// Compositor object to take care of GPU painting.
|
||||
// A Browser compositor object is responsible for generating the final
|
||||
// displayable form of pixels comprising a single widget's contents. It draws an
|
||||
@@ -215,6 +227,9 @@ class COMPOSITOR_EXPORT Compositor : public cc::LayerTreeHostClient,
|
||||
@@ -218,6 +230,9 @@ class COMPOSITOR_EXPORT Compositor : public cc::LayerTreeHostClient,
|
||||
// Schedules a redraw of the layer tree associated with this compositor.
|
||||
void ScheduleDraw();
|
||||
|
||||
@@ -56,7 +63,7 @@ index d842aa55175b..5683e6fb68f8 100644
|
||||
// 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
|
||||
@@ -426,6 +441,8 @@ class COMPOSITOR_EXPORT Compositor : public cc::LayerTreeHostClient,
|
||||
@@ -436,6 +451,8 @@ class COMPOSITOR_EXPORT Compositor : public cc::LayerTreeHostClient,
|
||||
ui::ContextFactory* context_factory_;
|
||||
ui::ContextFactoryPrivate* context_factory_private_;
|
||||
|
||||
|
@@ -50,21 +50,6 @@ index 8027836d925e..71f8d5a3f9dc 100644
|
||||
&pdf_plugin_info)) {
|
||||
return nullptr;
|
||||
}
|
||||
diff --git chrome/browser/plugins/plugin_info_message_filter.cc chrome/browser/plugins/plugin_info_message_filter.cc
|
||||
index 5a807cdf51a2..7cec2bdb773b 100644
|
||||
--- chrome/browser/plugins/plugin_info_message_filter.cc
|
||||
+++ chrome/browser/plugins/plugin_info_message_filter.cc
|
||||
@@ -468,8 +468,8 @@ bool PluginInfoMessageFilter::Context::FindEnabledPlugin(
|
||||
for (; i < matching_plugins.size(); ++i) {
|
||||
if (!filter ||
|
||||
filter->IsPluginAvailable(render_process_id_, render_frame_id,
|
||||
- resource_context_, url, main_frame_origin,
|
||||
- &matching_plugins[i])) {
|
||||
+ resource_context_, url, true,
|
||||
+ main_frame_origin, &matching_plugins[i])) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
diff --git chrome/browser/ui/cocoa/drag_util.mm chrome/browser/ui/cocoa/drag_util.mm
|
||||
index 6a2122ee1ed7..68831894695a 100644
|
||||
--- chrome/browser/ui/cocoa/drag_util.mm
|
||||
@@ -79,10 +64,10 @@ index 6a2122ee1ed7..68831894695a 100644
|
||||
}
|
||||
|
||||
diff --git chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
index ba2dacd6f420..803b5bc929bd 100644
|
||||
index 34c9855a251e..0e09454569e2 100644
|
||||
--- chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
+++ chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
@@ -597,6 +597,6 @@ void BrowserTabStripController::OnFindURLMimeTypeCompleted(
|
||||
@@ -596,6 +596,6 @@ void BrowserTabStripController::OnFindURLMimeTypeCompleted(
|
||||
content::PluginService::GetInstance()->GetPluginInfo(
|
||||
-1, // process ID
|
||||
MSG_ROUTING_NONE, // routing ID
|
||||
@@ -91,10 +76,10 @@ index ba2dacd6f420..803b5bc929bd 100644
|
||||
mime_type, false, NULL, &plugin, NULL));
|
||||
}
|
||||
diff --git content/browser/frame_host/navigation_handle_impl.cc content/browser/frame_host/navigation_handle_impl.cc
|
||||
index 28048bdb2046..b295b7a33601 100644
|
||||
index 73afa8b3908c..c9edab729e94 100644
|
||||
--- content/browser/frame_host/navigation_handle_impl.cc
|
||||
+++ content/browser/frame_host/navigation_handle_impl.cc
|
||||
@@ -312,12 +312,6 @@ net::Error NavigationHandleImpl::GetNetErrorCode() {
|
||||
@@ -321,12 +321,6 @@ net::Error NavigationHandleImpl::GetNetErrorCode() {
|
||||
}
|
||||
|
||||
RenderFrameHostImpl* NavigationHandleImpl::GetRenderFrameHost() {
|
||||
@@ -108,23 +93,10 @@ index 28048bdb2046..b295b7a33601 100644
|
||||
}
|
||||
|
||||
diff --git content/browser/frame_host/render_frame_host_impl.cc content/browser/frame_host/render_frame_host_impl.cc
|
||||
index 2b2e16f95e48..17731d783a63 100644
|
||||
index 1a4440241992..172190cb3339 100644
|
||||
--- content/browser/frame_host/render_frame_host_impl.cc
|
||||
+++ content/browser/frame_host/render_frame_host_impl.cc
|
||||
@@ -359,9 +359,9 @@ void ForwardRequest(const char* service_name,
|
||||
|
||||
void CreatePaymentManager(RenderFrameHostImpl* rfh,
|
||||
payments::mojom::PaymentManagerRequest request) {
|
||||
- StoragePartitionImpl* storage_partition =
|
||||
- static_cast<StoragePartitionImpl*>(BrowserContext::GetStoragePartition(
|
||||
- rfh->GetSiteInstance()->GetBrowserContext(), rfh->GetSiteInstance()));
|
||||
+ StoragePartition* storage_partition =
|
||||
+ BrowserContext::GetStoragePartition(
|
||||
+ rfh->GetSiteInstance()->GetBrowserContext(), rfh->GetSiteInstance());
|
||||
storage_partition->GetPaymentAppContext()->CreatePaymentManager(
|
||||
std::move(request));
|
||||
}
|
||||
@@ -1452,6 +1452,7 @@ void RenderFrameHostImpl::OnDidFailProvisionalLoadWithError(
|
||||
@@ -1499,6 +1499,7 @@ void RenderFrameHostImpl::OnDidFailProvisionalLoadWithError(
|
||||
if (navigation_handle_) {
|
||||
navigation_handle_->set_net_error_code(
|
||||
static_cast<net::Error>(params.error_code));
|
||||
@@ -132,11 +104,24 @@ index 2b2e16f95e48..17731d783a63 100644
|
||||
}
|
||||
|
||||
frame_tree_node_->navigator()->DidFailProvisionalLoadWithError(this, params);
|
||||
@@ -3484,9 +3485,9 @@ void RenderFrameHostImpl::CommitNavigation(
|
||||
// however only do this for cross-document navigations, because the
|
||||
// alternative would be redundant effort.
|
||||
mojom::URLLoaderFactoryPtr default_factory;
|
||||
- StoragePartitionImpl* storage_partition =
|
||||
- static_cast<StoragePartitionImpl*>(BrowserContext::GetStoragePartition(
|
||||
- GetSiteInstance()->GetBrowserContext(), GetSiteInstance()));
|
||||
+ StoragePartition* storage_partition =
|
||||
+ BrowserContext::GetStoragePartition(
|
||||
+ GetSiteInstance()->GetBrowserContext(), GetSiteInstance());
|
||||
if (subresource_loader_params &&
|
||||
subresource_loader_params->loader_factory_info.is_valid()) {
|
||||
// If the caller has supplied a default URLLoaderFactory override (for
|
||||
diff --git content/browser/frame_host/render_frame_message_filter.cc content/browser/frame_host/render_frame_message_filter.cc
|
||||
index a842664b32a8..93b489020e2a 100644
|
||||
index 4099c6a7ea9f..5c0d94d6062d 100644
|
||||
--- content/browser/frame_host/render_frame_message_filter.cc
|
||||
+++ content/browser/frame_host/render_frame_message_filter.cc
|
||||
@@ -516,6 +516,7 @@ void RenderFrameMessageFilter::GetCookies(int render_frame_id,
|
||||
@@ -542,6 +542,7 @@ void RenderFrameMessageFilter::GetCookies(int render_frame_id,
|
||||
|
||||
void RenderFrameMessageFilter::OnGetPlugins(
|
||||
bool refresh,
|
||||
@@ -144,7 +129,7 @@ index a842664b32a8..93b489020e2a 100644
|
||||
const url::Origin& main_frame_origin,
|
||||
IPC::Message* reply_msg) {
|
||||
// Don't refresh if the specified threshold has not been passed. Note that
|
||||
@@ -537,18 +538,19 @@ void RenderFrameMessageFilter::OnGetPlugins(
|
||||
@@ -563,18 +564,19 @@ void RenderFrameMessageFilter::OnGetPlugins(
|
||||
|
||||
PluginServiceImpl::GetInstance()->GetPlugins(
|
||||
base::BindOnce(&RenderFrameMessageFilter::GetPluginsCallback, this,
|
||||
@@ -166,7 +151,7 @@ index a842664b32a8..93b489020e2a 100644
|
||||
int routing_id = MSG_ROUTING_NONE;
|
||||
// In this loop, copy the WebPluginInfo (and do not use a reference) because
|
||||
// the filter might mutate it.
|
||||
@@ -557,7 +559,7 @@ void RenderFrameMessageFilter::GetPluginsCallback(
|
||||
@@ -583,7 +585,7 @@ void RenderFrameMessageFilter::GetPluginsCallback(
|
||||
if (!filter ||
|
||||
filter->IsPluginAvailable(child_process_id, routing_id,
|
||||
resource_context_, main_frame_origin.GetURL(),
|
||||
@@ -175,7 +160,7 @@ index a842664b32a8..93b489020e2a 100644
|
||||
plugins.push_back(plugin);
|
||||
}
|
||||
}
|
||||
@@ -569,6 +571,7 @@ void RenderFrameMessageFilter::GetPluginsCallback(
|
||||
@@ -595,6 +597,7 @@ void RenderFrameMessageFilter::GetPluginsCallback(
|
||||
void RenderFrameMessageFilter::OnGetPluginInfo(
|
||||
int render_frame_id,
|
||||
const GURL& url,
|
||||
@@ -183,7 +168,7 @@ index a842664b32a8..93b489020e2a 100644
|
||||
const url::Origin& main_frame_origin,
|
||||
const std::string& mime_type,
|
||||
bool* found,
|
||||
@@ -577,8 +580,8 @@ void RenderFrameMessageFilter::OnGetPluginInfo(
|
||||
@@ -603,8 +606,8 @@ void RenderFrameMessageFilter::OnGetPluginInfo(
|
||||
bool allow_wildcard = true;
|
||||
*found = plugin_service_->GetPluginInfo(
|
||||
render_process_id_, render_frame_id, resource_context_, url,
|
||||
@@ -195,10 +180,10 @@ index a842664b32a8..93b489020e2a 100644
|
||||
|
||||
void RenderFrameMessageFilter::OnOpenChannelToPepperPlugin(
|
||||
diff --git content/browser/frame_host/render_frame_message_filter.h content/browser/frame_host/render_frame_message_filter.h
|
||||
index 1826101c76d0..eafe5930cfc1 100644
|
||||
index 0b884a7558a9..98ecd1ca2460 100644
|
||||
--- content/browser/frame_host/render_frame_message_filter.h
|
||||
+++ content/browser/frame_host/render_frame_message_filter.h
|
||||
@@ -130,13 +130,16 @@ class CONTENT_EXPORT RenderFrameMessageFilter
|
||||
@@ -136,13 +136,16 @@ class CONTENT_EXPORT RenderFrameMessageFilter
|
||||
|
||||
#if BUILDFLAG(ENABLE_PLUGINS)
|
||||
void OnGetPlugins(bool refresh,
|
||||
@@ -216,25 +201,25 @@ index 1826101c76d0..eafe5930cfc1 100644
|
||||
const std::string& mime_type,
|
||||
bool* found,
|
||||
diff --git content/browser/loader/mime_sniffing_resource_handler.cc content/browser/loader/mime_sniffing_resource_handler.cc
|
||||
index 482bb55c2bfe..fbbac2ab26b1 100644
|
||||
index 130041fe86c2..90b4e6e21167 100644
|
||||
--- content/browser/loader/mime_sniffing_resource_handler.cc
|
||||
+++ content/browser/loader/mime_sniffing_resource_handler.cc
|
||||
@@ -489,8 +489,8 @@ bool MimeSniffingResourceHandler::CheckForPluginHandler(
|
||||
@@ -449,8 +449,8 @@ bool MimeSniffingResourceHandler::CheckForPluginHandler(
|
||||
WebPluginInfo plugin;
|
||||
bool has_plugin = plugin_service_->GetPluginInfo(
|
||||
info->GetChildID(), info->GetRenderFrameID(), info->GetContext(),
|
||||
- request()->url(), url::Origin(), response_->head.mime_type,
|
||||
- allow_wildcard, &stale, &plugin, NULL);
|
||||
- allow_wildcard, &stale, &plugin, nullptr);
|
||||
+ request()->url(), info->IsMainFrame(), url::Origin(),
|
||||
+ response_->head.mime_type, allow_wildcard, &stale, &plugin, NULL);
|
||||
+ response_->head.mime_type, allow_wildcard, &stale, &plugin, nullptr);
|
||||
|
||||
if (stale) {
|
||||
// Refresh the plugins asynchronously.
|
||||
diff --git content/browser/plugin_service_impl.cc content/browser/plugin_service_impl.cc
|
||||
index 4bdfa1d5455f..cf9b9166ae43 100644
|
||||
index 0378ab3c5013..21b7157f7ac8 100644
|
||||
--- content/browser/plugin_service_impl.cc
|
||||
+++ content/browser/plugin_service_impl.cc
|
||||
@@ -242,6 +242,7 @@ bool PluginServiceImpl::GetPluginInfo(int render_process_id,
|
||||
@@ -260,6 +260,7 @@ bool PluginServiceImpl::GetPluginInfo(int render_process_id,
|
||||
int render_frame_id,
|
||||
ResourceContext* context,
|
||||
const GURL& url,
|
||||
@@ -242,7 +227,7 @@ index 4bdfa1d5455f..cf9b9166ae43 100644
|
||||
const url::Origin& main_frame_origin,
|
||||
const std::string& mime_type,
|
||||
bool allow_wildcard,
|
||||
@@ -258,7 +259,8 @@ bool PluginServiceImpl::GetPluginInfo(int render_process_id,
|
||||
@@ -276,7 +277,8 @@ bool PluginServiceImpl::GetPluginInfo(int render_process_id,
|
||||
for (size_t i = 0; i < plugins.size(); ++i) {
|
||||
if (!filter_ ||
|
||||
filter_->IsPluginAvailable(render_process_id, render_frame_id, context,
|
||||
@@ -253,7 +238,7 @@ index 4bdfa1d5455f..cf9b9166ae43 100644
|
||||
if (actual_mime_type)
|
||||
*actual_mime_type = mime_types[i];
|
||||
diff --git content/browser/plugin_service_impl.h content/browser/plugin_service_impl.h
|
||||
index b654bf3c98b4..1b09cd3d0a23 100644
|
||||
index fb9226fd1b1c..0e13f2df47a3 100644
|
||||
--- content/browser/plugin_service_impl.h
|
||||
+++ content/browser/plugin_service_impl.h
|
||||
@@ -63,6 +63,7 @@ class CONTENT_EXPORT PluginServiceImpl : public PluginService {
|
||||
@@ -265,10 +250,10 @@ index b654bf3c98b4..1b09cd3d0a23 100644
|
||||
const std::string& mime_type,
|
||||
bool allow_wildcard,
|
||||
diff --git content/common/frame_messages.h content/common/frame_messages.h
|
||||
index 18c4b420d781..c9cd1cac49fc 100644
|
||||
index 3e00480ee1bc..34421dcd3c20 100644
|
||||
--- content/common/frame_messages.h
|
||||
+++ content/common/frame_messages.h
|
||||
@@ -1327,8 +1327,9 @@ IPC_MESSAGE_ROUTED1(FrameHostMsg_PepperStopsPlayback,
|
||||
@@ -1359,8 +1359,9 @@ IPC_MESSAGE_ROUTED1(FrameHostMsg_PepperStopsPlayback,
|
||||
|
||||
// Used to get the list of plugins. |main_frame_origin| is used to handle
|
||||
// exceptions for plugin content settings.
|
||||
@@ -279,7 +264,7 @@ index 18c4b420d781..c9cd1cac49fc 100644
|
||||
url::Origin /* main_frame_origin */,
|
||||
std::vector<content::WebPluginInfo> /* plugins */)
|
||||
|
||||
@@ -1336,9 +1337,10 @@ IPC_SYNC_MESSAGE_CONTROL2_1(FrameHostMsg_GetPlugins,
|
||||
@@ -1368,9 +1369,10 @@ IPC_SYNC_MESSAGE_CONTROL2_1(FrameHostMsg_GetPlugins,
|
||||
// type. If there is no matching plugin, |found| is false.
|
||||
// |actual_mime_type| is the actual mime type supported by the
|
||||
// found plugin.
|
||||
@@ -292,10 +277,10 @@ index 18c4b420d781..c9cd1cac49fc 100644
|
||||
std::string /* mime_type */,
|
||||
bool /* found */,
|
||||
diff --git content/ppapi_plugin/ppapi_blink_platform_impl.cc content/ppapi_plugin/ppapi_blink_platform_impl.cc
|
||||
index e26ffe9ab2d0..3bbe19ae4146 100644
|
||||
index bf3c786b5093..ea8f85700e86 100644
|
||||
--- content/ppapi_plugin/ppapi_blink_platform_impl.cc
|
||||
+++ content/ppapi_plugin/ppapi_blink_platform_impl.cc
|
||||
@@ -207,6 +207,7 @@ std::unique_ptr<blink::WebURLLoader> PpapiBlinkPlatformImpl::CreateURLLoader(
|
||||
@@ -199,6 +199,7 @@ blink::WebThemeEngine* PpapiBlinkPlatformImpl::ThemeEngine() {
|
||||
|
||||
void PpapiBlinkPlatformImpl::GetPluginList(
|
||||
bool refresh,
|
||||
@@ -304,12 +289,12 @@ index e26ffe9ab2d0..3bbe19ae4146 100644
|
||||
blink::WebPluginListBuilder* builder) {
|
||||
NOTREACHED();
|
||||
diff --git content/ppapi_plugin/ppapi_blink_platform_impl.h content/ppapi_plugin/ppapi_blink_platform_impl.h
|
||||
index dfc2f2b1f4c6..d931301523ec 100644
|
||||
index 8a58a2ae1e2f..21b18ff2eba7 100644
|
||||
--- content/ppapi_plugin/ppapi_blink_platform_impl.h
|
||||
+++ content/ppapi_plugin/ppapi_blink_platform_impl.h
|
||||
@@ -43,6 +43,7 @@ class PpapiBlinkPlatformImpl : public BlinkPlatformImpl {
|
||||
const blink::WebURLRequest& request,
|
||||
scoped_refptr<base::SingleThreadTaskRunner> task_runner) override;
|
||||
@@ -40,6 +40,7 @@ class PpapiBlinkPlatformImpl : public BlinkPlatformImpl {
|
||||
blink::WebString DefaultLocale() override;
|
||||
blink::WebThemeEngine* ThemeEngine() override;
|
||||
void GetPluginList(bool refresh,
|
||||
+ bool isMainFrame,
|
||||
const blink::WebSecurityOrigin& mainFrameOrigin,
|
||||
@@ -340,10 +325,10 @@ index 3b610b1f554e..7c439e060779 100644
|
||||
WebPluginInfo* plugin) = 0;
|
||||
|
||||
diff --git content/public/renderer/content_renderer_client.cc content/public/renderer/content_renderer_client.cc
|
||||
index d8a56e64875d..4b66b2fc0efc 100644
|
||||
index 3e3d132705a8..4a972b4475e6 100644
|
||||
--- content/public/renderer/content_renderer_client.cc
|
||||
+++ content/public/renderer/content_renderer_client.cc
|
||||
@@ -103,7 +103,6 @@ bool ContentRendererClient::AllowPopup() {
|
||||
@@ -101,7 +101,6 @@ bool ContentRendererClient::AllowPopup() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -351,7 +336,7 @@ index d8a56e64875d..4b66b2fc0efc 100644
|
||||
bool ContentRendererClient::HandleNavigation(
|
||||
RenderFrame* render_frame,
|
||||
bool is_content_initiated,
|
||||
@@ -116,6 +115,7 @@ bool ContentRendererClient::HandleNavigation(
|
||||
@@ -114,6 +113,7 @@ bool ContentRendererClient::HandleNavigation(
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -360,10 +345,10 @@ index d8a56e64875d..4b66b2fc0efc 100644
|
||||
return false;
|
||||
}
|
||||
diff --git content/public/renderer/content_renderer_client.h content/public/renderer/content_renderer_client.h
|
||||
index a05d000287b6..682a3e61d980 100644
|
||||
index 3d34633700dd..6cee67f439f7 100644
|
||||
--- content/public/renderer/content_renderer_client.h
|
||||
+++ content/public/renderer/content_renderer_client.h
|
||||
@@ -75,6 +75,9 @@ class CONTENT_EXPORT ContentRendererClient {
|
||||
@@ -73,6 +73,9 @@ class CONTENT_EXPORT ContentRendererClient {
|
||||
// Notifies us that the RenderThread has been created.
|
||||
virtual void RenderThreadStarted() {}
|
||||
|
||||
@@ -373,7 +358,7 @@ index a05d000287b6..682a3e61d980 100644
|
||||
// Notifies that a new RenderFrame has been created.
|
||||
virtual void RenderFrameCreated(RenderFrame* render_frame) {}
|
||||
|
||||
@@ -193,7 +196,6 @@ class CONTENT_EXPORT ContentRendererClient {
|
||||
@@ -190,7 +193,6 @@ class CONTENT_EXPORT ContentRendererClient {
|
||||
// Returns true if a popup window should be allowed.
|
||||
virtual bool AllowPopup();
|
||||
|
||||
@@ -381,7 +366,7 @@ index a05d000287b6..682a3e61d980 100644
|
||||
// TODO(sgurun) This callback is deprecated and will be removed as soon
|
||||
// as android webview completes implementation of a resource throttle based
|
||||
// shouldoverrideurl implementation. See crbug.com/325351
|
||||
@@ -209,6 +211,7 @@ class CONTENT_EXPORT ContentRendererClient {
|
||||
@@ -206,6 +208,7 @@ class CONTENT_EXPORT ContentRendererClient {
|
||||
blink::WebNavigationPolicy default_policy,
|
||||
bool is_redirect);
|
||||
|
||||
@@ -389,6 +374,19 @@ index a05d000287b6..682a3e61d980 100644
|
||||
// Indicates if the Android MediaPlayer should be used instead of Chrome's
|
||||
// built in media player for the given |url|. Defaults to false.
|
||||
virtual bool ShouldUseMediaPlayerForURL(const GURL& url);
|
||||
@@ -331,6 +334,12 @@ class CONTENT_EXPORT ContentRendererClient {
|
||||
// This method may invalidate the frame.
|
||||
virtual void RunScriptsAtDocumentIdle(RenderFrame* render_frame) {}
|
||||
|
||||
+ // Notifies that a DevTools agent has attached or detached.
|
||||
+ virtual void DevToolsAgentAttached(RenderFrame* render_frame,
|
||||
+ int session_id) {}
|
||||
+ virtual void DevToolsAgentDetached(RenderFrame* render_frame,
|
||||
+ int session_id) {}
|
||||
+
|
||||
// Allows subclasses to enable some runtime features before Blink has
|
||||
// started.
|
||||
virtual void SetRuntimeFeaturesDefaultsBeforeBlinkInitialization() {}
|
||||
diff --git content/public/renderer/render_frame_observer.h content/public/renderer/render_frame_observer.h
|
||||
index 4f8478bfa87a..52471407518e 100644
|
||||
--- content/public/renderer/render_frame_observer.h
|
||||
@@ -403,11 +401,54 @@ index 4f8478bfa87a..52471407518e 100644
|
||||
// Called when the focused node has changed to |node|.
|
||||
virtual void FocusedNodeChanged(const blink::WebNode& node) {}
|
||||
|
||||
diff --git content/renderer/devtools/devtools_agent.cc content/renderer/devtools/devtools_agent.cc
|
||||
index 685c39f6aca2..cee77800770a 100644
|
||||
--- content/renderer/devtools/devtools_agent.cc
|
||||
+++ content/renderer/devtools/devtools_agent.cc
|
||||
@@ -20,7 +20,9 @@
|
||||
#include "content/child/child_process.h"
|
||||
#include "content/common/devtools_messages.h"
|
||||
#include "content/common/frame_messages.h"
|
||||
+#include "content/public/common/content_client.h"
|
||||
#include "content/public/common/manifest.h"
|
||||
+#include "content/public/renderer/content_renderer_client.h"
|
||||
#include "content/renderer/devtools/devtools_cpu_throttler.h"
|
||||
#include "content/renderer/render_frame_impl.h"
|
||||
#include "content/renderer/render_widget.h"
|
||||
@@ -218,6 +220,8 @@ void DevToolsAgent::AttachDevToolsSession(
|
||||
GetWebAgent()->Attach(session_id);
|
||||
}
|
||||
|
||||
+ GetContentClient()->renderer()->DevToolsAgentAttached(frame_, session_id);
|
||||
+
|
||||
sessions_[session_id].reset(
|
||||
new Session(session_id, this, std::move(session)));
|
||||
|
||||
@@ -237,6 +241,7 @@ void DevToolsAgent::AttachDevToolsSession(
|
||||
|
||||
void DevToolsAgent::DetachSession(int session_id) {
|
||||
GetWebAgent()->Detach(session_id);
|
||||
+ GetContentClient()->renderer()->DevToolsAgentDetached(frame_, session_id);
|
||||
io_sessions_.erase(session_id);
|
||||
sessions_.erase(session_id);
|
||||
hosts_.erase(session_id);
|
||||
@@ -382,8 +387,10 @@ bool DevToolsAgent::IsAttached() {
|
||||
}
|
||||
|
||||
void DevToolsAgent::DetachAllSessions() {
|
||||
- for (auto& it : hosts_)
|
||||
+ for (auto& it : hosts_) {
|
||||
GetWebAgent()->Detach(it.first);
|
||||
+ GetContentClient()->renderer()->DevToolsAgentDetached(frame_, it.first);
|
||||
+ }
|
||||
hosts_.clear();
|
||||
io_sessions_.clear();
|
||||
sessions_.clear();
|
||||
diff --git content/renderer/render_frame_impl.cc content/renderer/render_frame_impl.cc
|
||||
index 285d1d6fb031..8024d725d86c 100644
|
||||
index 40f9cef599dc..323084e643d7 100644
|
||||
--- content/renderer/render_frame_impl.cc
|
||||
+++ content/renderer/render_frame_impl.cc
|
||||
@@ -2975,7 +2975,8 @@ blink::WebPlugin* RenderFrameImpl::CreatePlugin(
|
||||
@@ -3210,7 +3210,8 @@ blink::WebPlugin* RenderFrameImpl::CreatePlugin(
|
||||
std::string mime_type;
|
||||
bool found = false;
|
||||
Send(new FrameHostMsg_GetPluginInfo(
|
||||
@@ -417,7 +458,7 @@ index 285d1d6fb031..8024d725d86c 100644
|
||||
params.mime_type.Utf8(), &found, &info, &mime_type));
|
||||
if (!found)
|
||||
return nullptr;
|
||||
@@ -3283,6 +3284,8 @@ void RenderFrameImpl::FrameDetached(DetachType type) {
|
||||
@@ -3552,6 +3553,8 @@ void RenderFrameImpl::FrameDetached(DetachType type) {
|
||||
|
||||
void RenderFrameImpl::FrameFocused() {
|
||||
Send(new FrameHostMsg_FrameFocused(routing_id_));
|
||||
@@ -426,7 +467,7 @@ index 285d1d6fb031..8024d725d86c 100644
|
||||
}
|
||||
|
||||
void RenderFrameImpl::WillCommitProvisionalLoad() {
|
||||
@@ -5459,9 +5462,8 @@ WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation(
|
||||
@@ -5643,9 +5646,8 @@ WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation(
|
||||
(!IsBrowserSideNavigationEnabled() ||
|
||||
url != pending_navigation_params_->request_params.redirects[0]));
|
||||
|
||||
@@ -438,7 +479,7 @@ index 285d1d6fb031..8024d725d86c 100644
|
||||
// The handlenavigation API is deprecated and will be removed once
|
||||
// crbug.com/325351 is resolved.
|
||||
if ((!IsBrowserSideNavigationEnabled() || !IsURLHandledByNetworkStack(url)) &&
|
||||
@@ -5471,7 +5473,6 @@ WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation(
|
||||
@@ -5655,7 +5657,6 @@ WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation(
|
||||
is_redirect)) {
|
||||
return blink::kWebNavigationPolicyIgnore;
|
||||
}
|
||||
@@ -447,10 +488,10 @@ index 285d1d6fb031..8024d725d86c 100644
|
||||
// If the browser is interested, then give it a chance to look at the request.
|
||||
if (is_content_initiated && IsTopLevelNavigation(frame_) &&
|
||||
diff --git content/renderer/render_thread_impl.cc content/renderer/render_thread_impl.cc
|
||||
index dc0111728c3e..b8ab8834fc97 100644
|
||||
index 10b32b1254c6..6ba3dfbe9d15 100644
|
||||
--- content/renderer/render_thread_impl.cc
|
||||
+++ content/renderer/render_thread_impl.cc
|
||||
@@ -779,6 +779,8 @@ void RenderThreadImpl::Init(
|
||||
@@ -819,6 +819,8 @@ void RenderThreadImpl::Init(
|
||||
|
||||
StartServiceManagerConnection();
|
||||
|
||||
@@ -460,10 +501,10 @@ index dc0111728c3e..b8ab8834fc97 100644
|
||||
base::Bind(&RenderThreadImpl::OnRendererInterfaceRequest,
|
||||
base::Unretained(this)));
|
||||
diff --git content/renderer/renderer_blink_platform_impl.cc content/renderer/renderer_blink_platform_impl.cc
|
||||
index 1a9d6c2e7ef2..25166d5d9730 100644
|
||||
index 3cd99e14d1d5..96e8d51625d7 100644
|
||||
--- content/renderer/renderer_blink_platform_impl.cc
|
||||
+++ content/renderer/renderer_blink_platform_impl.cc
|
||||
@@ -794,6 +794,7 @@ RendererBlinkPlatformImpl::CreateMIDIAccessor(
|
||||
@@ -846,6 +846,7 @@ RendererBlinkPlatformImpl::CreateMIDIAccessor(
|
||||
|
||||
void RendererBlinkPlatformImpl::GetPluginList(
|
||||
bool refresh,
|
||||
@@ -471,7 +512,7 @@ index 1a9d6c2e7ef2..25166d5d9730 100644
|
||||
const blink::WebSecurityOrigin& mainFrameOrigin,
|
||||
blink::WebPluginListBuilder* builder) {
|
||||
#if BUILDFLAG(ENABLE_PLUGINS)
|
||||
@@ -801,7 +802,8 @@ void RendererBlinkPlatformImpl::GetPluginList(
|
||||
@@ -853,7 +854,8 @@ void RendererBlinkPlatformImpl::GetPluginList(
|
||||
if (!plugin_refresh_allowed_)
|
||||
refresh = false;
|
||||
RenderThread::Get()->Send(
|
||||
@@ -482,10 +523,10 @@ index 1a9d6c2e7ef2..25166d5d9730 100644
|
||||
builder->AddPlugin(WebString::FromUTF16(plugin.name),
|
||||
WebString::FromUTF16(plugin.desc),
|
||||
diff --git content/renderer/renderer_blink_platform_impl.h content/renderer/renderer_blink_platform_impl.h
|
||||
index 8d68defb758a..6891eb484eec 100644
|
||||
index 72649102bfcc..6067abc4c8c0 100644
|
||||
--- content/renderer/renderer_blink_platform_impl.h
|
||||
+++ content/renderer/renderer_blink_platform_impl.h
|
||||
@@ -126,6 +126,7 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
|
||||
@@ -130,6 +130,7 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
|
||||
viz::FrameSinkId GenerateFrameSinkId() override;
|
||||
|
||||
void GetPluginList(bool refresh,
|
||||
@@ -542,10 +583,10 @@ index db23a83ed079..57a4c536118c 100644
|
||||
const std::string& mime_type,
|
||||
bool allow_wildcard,
|
||||
diff --git content/test/test_blink_web_unit_test_support.cc content/test/test_blink_web_unit_test_support.cc
|
||||
index 9f4c763b336b..2cd2087d11e3 100644
|
||||
index cb545a4ddea4..f21d056e50a2 100644
|
||||
--- content/test/test_blink_web_unit_test_support.cc
|
||||
+++ content/test/test_blink_web_unit_test_support.cc
|
||||
@@ -290,6 +290,7 @@ blink::WebThread* TestBlinkWebUnitTestSupport::CurrentThread() {
|
||||
@@ -318,6 +318,7 @@ blink::WebThread* TestBlinkWebUnitTestSupport::CurrentThread() {
|
||||
|
||||
void TestBlinkWebUnitTestSupport::GetPluginList(
|
||||
bool refresh,
|
||||
@@ -554,7 +595,7 @@ index 9f4c763b336b..2cd2087d11e3 100644
|
||||
blink::WebPluginListBuilder* builder) {
|
||||
builder->AddPlugin("pdf", "pdf", "pdf-files");
|
||||
diff --git content/test/test_blink_web_unit_test_support.h content/test/test_blink_web_unit_test_support.h
|
||||
index 93df7c8c312a..7829493c88a3 100644
|
||||
index 200f40eb51f5..afba549f0cdf 100644
|
||||
--- content/test/test_blink_web_unit_test_support.h
|
||||
+++ content/test/test_blink_web_unit_test_support.h
|
||||
@@ -70,6 +70,7 @@ class TestBlinkWebUnitTestSupport : public BlinkPlatformImpl {
|
||||
|
@@ -1,37 +1,5 @@
|
||||
diff --git build/secondary/third_party/crashpad/crashpad/handler/BUILD.gn build/secondary/third_party/crashpad/crashpad/handler/BUILD.gn
|
||||
index 4d385dd5512b..1b51f2d17491 100644
|
||||
--- build/secondary/third_party/crashpad/crashpad/handler/BUILD.gn
|
||||
+++ build/secondary/third_party/crashpad/crashpad/handler/BUILD.gn
|
||||
@@ -2,6 +2,8 @@
|
||||
# Use of this source code is governed by a BSD-style license that can be
|
||||
# found in the LICENSE file.
|
||||
|
||||
+import("//cef/libcef/features/features.gni")
|
||||
+
|
||||
static_library("handler_lib") {
|
||||
sources = [
|
||||
"crash_report_upload_thread.cc",
|
||||
@@ -30,8 +32,18 @@ static_library("handler_lib") {
|
||||
"../snapshot",
|
||||
"../tools:tool_support",
|
||||
"//base",
|
||||
+ "//cef/libcef/features",
|
||||
]
|
||||
|
||||
+ if (enable_cef) {
|
||||
+ sources += [
|
||||
+ "//cef/libcef/common/cef_crash_report_upload_thread.cc",
|
||||
+ "//cef/libcef/common/cef_crash_report_upload_thread.h",
|
||||
+ ]
|
||||
+
|
||||
+ include_dirs += [ "//cef" ]
|
||||
+ }
|
||||
+
|
||||
if (is_win) {
|
||||
cflags = [ "/wd4201" ]
|
||||
}
|
||||
diff --git chrome/common/crash_keys.cc chrome/common/crash_keys.cc
|
||||
index ff516e246948..47e474c1840d 100644
|
||||
index 631772316423..f00a94403c61 100644
|
||||
--- chrome/common/crash_keys.cc
|
||||
+++ chrome/common/crash_keys.cc
|
||||
@@ -4,6 +4,8 @@
|
||||
@@ -43,7 +11,7 @@ index ff516e246948..47e474c1840d 100644
|
||||
#include "base/base_switches.h"
|
||||
#include "base/command_line.h"
|
||||
#include "base/format_macros.h"
|
||||
@@ -89,7 +91,7 @@ const char kZeroEncodeDetails[] = "zero-encode-details";
|
||||
@@ -84,7 +86,7 @@ const char kViewCount[] = "view-count";
|
||||
const char kUserCloudPolicyManagerConnectTrace[] =
|
||||
"user-cloud-policy-manager-connect-trace";
|
||||
|
||||
@@ -52,7 +20,7 @@ index ff516e246948..47e474c1840d 100644
|
||||
// The following keys may be chunked by the underlying crash logging system,
|
||||
// but ultimately constitute a single key-value pair.
|
||||
//
|
||||
@@ -223,10 +225,16 @@ size_t RegisterChromeCrashKeys() {
|
||||
@@ -200,10 +202,16 @@ size_t RegisterChromeCrashKeys() {
|
||||
|
||||
// This dynamic set of keys is used for sets of key value pairs when gathering
|
||||
// a collection of data, like command line switches or extension IDs.
|
||||
@@ -71,7 +39,7 @@ index ff516e246948..47e474c1840d 100644
|
||||
|
||||
// Register the extension IDs.
|
||||
{
|
||||
@@ -260,7 +268,7 @@ size_t RegisterChromeCrashKeys() {
|
||||
@@ -237,7 +245,7 @@ size_t RegisterChromeCrashKeys() {
|
||||
return base::debug::InitCrashKeys(&keys.at(0), keys.size(), kChunkMaxLength);
|
||||
}
|
||||
|
||||
@@ -80,7 +48,7 @@ index ff516e246948..47e474c1840d 100644
|
||||
static const char* const kIgnoreSwitches[] = {
|
||||
switches::kEnableLogging,
|
||||
switches::kFlagSwitchesBegin,
|
||||
@@ -316,7 +324,7 @@ static bool IsBoringSwitch(const std::string& flag) {
|
||||
@@ -292,7 +300,7 @@ static bool IsBoringSwitch(const std::string& flag) {
|
||||
}
|
||||
|
||||
void SetCrashKeysFromCommandLine(const base::CommandLine& command_line) {
|
||||
@@ -90,7 +58,7 @@ index ff516e246948..47e474c1840d 100644
|
||||
|
||||
void SetActiveExtensions(const std::set<std::string>& extensions) {
|
||||
diff --git chrome/common/crash_keys.h chrome/common/crash_keys.h
|
||||
index 687146e9e92c..b1b73d6e36b2 100644
|
||||
index 38e43f247477..62fe45582661 100644
|
||||
--- chrome/common/crash_keys.h
|
||||
+++ chrome/common/crash_keys.h
|
||||
@@ -22,10 +22,18 @@ class CommandLine;
|
||||
@@ -113,7 +81,7 @@ index 687146e9e92c..b1b73d6e36b2 100644
|
||||
// on the given |command_line|.
|
||||
void SetCrashKeysFromCommandLine(const base::CommandLine& command_line);
|
||||
diff --git chrome_elf/BUILD.gn chrome_elf/BUILD.gn
|
||||
index 1276a06ac02a..f5198bc4be48 100644
|
||||
index 60c6636bddf2..7e582f797653 100644
|
||||
--- chrome_elf/BUILD.gn
|
||||
+++ chrome_elf/BUILD.gn
|
||||
@@ -7,6 +7,7 @@
|
||||
@@ -124,7 +92,7 @@ index 1276a06ac02a..f5198bc4be48 100644
|
||||
import("//chrome/process_version_rc_template.gni")
|
||||
import("//testing/test.gni")
|
||||
|
||||
@@ -166,9 +167,6 @@ static_library("blacklist") {
|
||||
@@ -174,9 +175,6 @@ static_library("blacklist") {
|
||||
|
||||
static_library("crash") {
|
||||
sources = [
|
||||
@@ -134,7 +102,7 @@ index 1276a06ac02a..f5198bc4be48 100644
|
||||
"crash/crash_helper.cc",
|
||||
"crash/crash_helper.h",
|
||||
]
|
||||
@@ -176,6 +174,7 @@ static_library("crash") {
|
||||
@@ -184,6 +182,7 @@ static_library("crash") {
|
||||
":hook_util",
|
||||
"//base", # This needs to go. DEP of app, crash_keys, client.
|
||||
"//base:base_static", # pe_image
|
||||
@@ -142,7 +110,7 @@ index 1276a06ac02a..f5198bc4be48 100644
|
||||
"//chrome/install_static:install_static_util",
|
||||
"//components/crash/content/app",
|
||||
"//components/crash/core/common", # crash_keys
|
||||
@@ -184,6 +183,17 @@ static_library("crash") {
|
||||
@@ -192,6 +191,17 @@ static_library("crash") {
|
||||
"//gpu/config:crash_keys",
|
||||
"//third_party/crashpad/crashpad/client", # DumpWithoutCrash
|
||||
]
|
||||
@@ -195,7 +163,7 @@ index e8e27dc4ebd7..7cb2149ec41d 100644
|
||||
g_crash_helper_enabled = true;
|
||||
return true;
|
||||
diff --git components/crash/content/app/breakpad_linux.cc components/crash/content/app/breakpad_linux.cc
|
||||
index 526c410915f3..347385906357 100644
|
||||
index 42a50e8381c1..718f945573a3 100644
|
||||
--- components/crash/content/app/breakpad_linux.cc
|
||||
+++ components/crash/content/app/breakpad_linux.cc
|
||||
@@ -29,6 +29,7 @@
|
||||
@@ -214,7 +182,7 @@ index 526c410915f3..347385906357 100644
|
||||
#endif
|
||||
|
||||
bool g_is_crash_reporter_enabled = false;
|
||||
@@ -688,7 +690,7 @@ bool CrashDone(const MinidumpDescriptor& minidump,
|
||||
@@ -686,7 +688,7 @@ bool CrashDone(const MinidumpDescriptor& minidump,
|
||||
info.process_type_length = 7;
|
||||
info.distro = base::g_linux_distro;
|
||||
info.distro_length = my_strlen(base::g_linux_distro);
|
||||
@@ -223,7 +191,7 @@ index 526c410915f3..347385906357 100644
|
||||
info.process_start_time = g_process_start_time;
|
||||
info.oom_size = base::g_oom_size;
|
||||
info.pid = g_pid;
|
||||
@@ -1357,7 +1359,7 @@ void ExecUploadProcessOrTerminate(const BreakpadInfo& info,
|
||||
@@ -1356,7 +1358,7 @@ void ExecUploadProcessOrTerminate(const BreakpadInfo& info,
|
||||
header_content_encoding,
|
||||
header_content_type,
|
||||
post_file,
|
||||
@@ -254,7 +222,7 @@ index 526c410915f3..347385906357 100644
|
||||
if (info.pid > 0) {
|
||||
char pid_value_buf[kUint64StringSize];
|
||||
uint64_t pid_value_len = my_uint64_len(info.pid);
|
||||
@@ -2013,6 +2024,17 @@ void InitCrashReporter(const std::string& process_type) {
|
||||
@@ -2017,6 +2028,17 @@ void InitCrashReporter(const std::string& process_type) {
|
||||
PostEnableBreakpadInitialization();
|
||||
}
|
||||
|
||||
@@ -287,7 +255,7 @@ index 4a2a429fc052..70f3adbc73cf 100644
|
||||
extern void InitCrashKeysForTesting();
|
||||
|
||||
diff --git components/crash/content/app/crash_reporter_client.cc components/crash/content/app/crash_reporter_client.cc
|
||||
index 2e9ee28e1b00..de53f5927143 100644
|
||||
index 72849b964f1c..6a78f9b9c832 100644
|
||||
--- components/crash/content/app/crash_reporter_client.cc
|
||||
+++ components/crash/content/app/crash_reporter_client.cc
|
||||
@@ -88,11 +88,12 @@ int CrashReporterClient::GetResultCodeRespawnFailed() {
|
||||
@@ -356,7 +324,7 @@ index 2e9ee28e1b00..de53f5927143 100644
|
||||
-
|
||||
} // namespace crash_reporter
|
||||
diff --git components/crash/content/app/crash_reporter_client.h components/crash/content/app/crash_reporter_client.h
|
||||
index 46ba162cd35a..19afc3c6215f 100644
|
||||
index d2a805289c0d..25d026583c37 100644
|
||||
--- components/crash/content/app/crash_reporter_client.h
|
||||
+++ components/crash/content/app/crash_reporter_client.h
|
||||
@@ -8,6 +8,7 @@
|
||||
@@ -367,7 +335,7 @@ index 46ba162cd35a..19afc3c6215f 100644
|
||||
|
||||
#include "base/strings/string16.h"
|
||||
#include "build/build_config.h"
|
||||
@@ -104,12 +105,13 @@ class CrashReporterClient {
|
||||
@@ -93,12 +94,13 @@ class CrashReporterClient {
|
||||
virtual int GetResultCodeRespawnFailed();
|
||||
#endif
|
||||
|
||||
@@ -382,7 +350,7 @@ index 46ba162cd35a..19afc3c6215f 100644
|
||||
virtual base::FilePath GetReporterLogFilename();
|
||||
|
||||
// Custom crash minidump handler after the minidump is generated.
|
||||
@@ -118,6 +120,7 @@ class CrashReporterClient {
|
||||
@@ -107,6 +109,7 @@ class CrashReporterClient {
|
||||
// WARNING: this handler runs in a compromised context. It may not call into
|
||||
// libc nor allocate memory normally.
|
||||
virtual bool HandleCrashDump(const char* crashdump_filename);
|
||||
@@ -390,7 +358,7 @@ index 46ba162cd35a..19afc3c6215f 100644
|
||||
#endif
|
||||
|
||||
// The location where minidump files should be written. Returns true if
|
||||
@@ -197,6 +200,23 @@ class CrashReporterClient {
|
||||
@@ -186,6 +189,23 @@ class CrashReporterClient {
|
||||
|
||||
// Returns true if breakpad should run in the given process type.
|
||||
virtual bool EnableBreakpadForProcess(const std::string& process_type);
|
||||
@@ -415,10 +383,10 @@ index 46ba162cd35a..19afc3c6215f 100644
|
||||
|
||||
} // namespace crash_reporter
|
||||
diff --git components/crash/content/app/crashpad.cc components/crash/content/app/crashpad.cc
|
||||
index af31c1a40d4f..0452cfb5dc39 100644
|
||||
index 6949d5e7dcc4..d9b052382a6a 100644
|
||||
--- components/crash/content/app/crashpad.cc
|
||||
+++ components/crash/content/app/crashpad.cc
|
||||
@@ -135,7 +135,8 @@ void InitializeCrashpadImpl(bool initial_client,
|
||||
@@ -137,7 +137,8 @@ void InitializeCrashpadImpl(bool initial_client,
|
||||
// fallback. Forwarding is turned off for debug-mode builds even for the
|
||||
// browser process, because the system's crash reporter can take a very long
|
||||
// time to chew on symbols.
|
||||
@@ -600,7 +568,7 @@ index 3a33c9bb8e92..961d600f7452 100644
|
||||
|
||||
if (crash_reporter_client->ShouldMonitorCrashHandlerExpensively()) {
|
||||
diff --git content/browser/frame_host/debug_urls.cc content/browser/frame_host/debug_urls.cc
|
||||
index c1764c511286..46165027b9d8 100644
|
||||
index 46954327b9c7..62a7ce8d4e46 100644
|
||||
--- content/browser/frame_host/debug_urls.cc
|
||||
+++ content/browser/frame_host/debug_urls.cc
|
||||
@@ -139,7 +139,9 @@ bool HandleDebugURL(const GURL& url, ui::PageTransition transition) {
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git third_party/crashpad/crashpad/client/prune_crash_reports.cc third_party/crashpad/crashpad/client/prune_crash_reports.cc
|
||||
index 3aaaeee5d07f..d99fcb418d9e 100644
|
||||
index d045eb6a65a0..bc347a30ea26 100644
|
||||
--- third_party/crashpad/crashpad/client/prune_crash_reports.cc
|
||||
+++ third_party/crashpad/crashpad/client/prune_crash_reports.cc
|
||||
@@ -67,13 +67,19 @@ void PruneCrashReportDatabase(CrashReportDatabase* database,
|
||||
@@ -66,13 +66,19 @@ void PruneCrashReportDatabase(CrashReportDatabase* database,
|
||||
}
|
||||
|
||||
// static
|
||||
@@ -16,12 +16,12 @@ index 3aaaeee5d07f..d99fcb418d9e 100644
|
||||
+ max_size_in_mb = 128;
|
||||
+ if (max_age_in_days <= 0)
|
||||
+ max_age_in_days = 365;
|
||||
return base::WrapUnique(
|
||||
new BinaryPruneCondition(BinaryPruneCondition::OR,
|
||||
- new DatabaseSizePruneCondition(1024 * 128),
|
||||
- new AgePruneCondition(365)));
|
||||
+ new DatabaseSizePruneCondition(max_size_in_mb),
|
||||
+ new AgePruneCondition(max_age_in_days)));
|
||||
return std::make_unique<BinaryPruneCondition>(
|
||||
BinaryPruneCondition::OR,
|
||||
- new DatabaseSizePruneCondition(1024 * 128),
|
||||
- new AgePruneCondition(365));
|
||||
+ new DatabaseSizePruneCondition(1024 * max_size_in_mb),
|
||||
+ new AgePruneCondition(max_age_in_days));
|
||||
}
|
||||
|
||||
static const time_t kSecondsInDay = 60 * 60 * 24;
|
||||
@@ -145,11 +145,42 @@ index b64f74fbaf28..0c3c22e215b6 100644
|
||||
private:
|
||||
struct Data;
|
||||
|
||||
diff --git third_party/crashpad/crashpad/handler/BUILD.gn third_party/crashpad/crashpad/handler/BUILD.gn
|
||||
index 05f554b73036..5b6d1a2a98e1 100644
|
||||
--- third_party/crashpad/crashpad/handler/BUILD.gn
|
||||
+++ third_party/crashpad/crashpad/handler/BUILD.gn
|
||||
@@ -12,6 +12,7 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
+import("//cef/libcef/features/features.gni")
|
||||
import("//testing/test.gni")
|
||||
|
||||
static_library("handler") {
|
||||
@@ -56,8 +57,18 @@ static_library("handler") {
|
||||
"../tools:tool_support",
|
||||
"../util",
|
||||
"//base",
|
||||
+ "//cef/libcef/features",
|
||||
]
|
||||
|
||||
+ if (enable_cef) {
|
||||
+ sources += [
|
||||
+ "//cef/libcef/common/cef_crash_report_upload_thread.cc",
|
||||
+ "//cef/libcef/common/cef_crash_report_upload_thread.h",
|
||||
+ ]
|
||||
+
|
||||
+ configs += [ "//cef/libcef/features:config" ]
|
||||
+ }
|
||||
+
|
||||
if (is_win) {
|
||||
cflags = [ "/wd4201" ] # nonstandard extension used : nameless struct/union
|
||||
}
|
||||
diff --git third_party/crashpad/crashpad/handler/crash_report_upload_thread.h third_party/crashpad/crashpad/handler/crash_report_upload_thread.h
|
||||
index c769efed5c54..daec6cd17f37 100644
|
||||
index cdd1502b7e2f..db47f0a8b559 100644
|
||||
--- third_party/crashpad/crashpad/handler/crash_report_upload_thread.h
|
||||
+++ third_party/crashpad/crashpad/handler/crash_report_upload_thread.h
|
||||
@@ -89,7 +89,7 @@ class CrashReportUploadThread : public WorkerThread::Delegate {
|
||||
@@ -99,7 +99,7 @@ class CrashReportUploadThread : public WorkerThread::Delegate {
|
||||
//! This method may be called from any thread.
|
||||
void ReportPending(const UUID& report_uuid);
|
||||
|
||||
@@ -158,7 +189,7 @@ index c769efed5c54..daec6cd17f37 100644
|
||||
//! \brief The result code from UploadReport().
|
||||
enum class UploadResult {
|
||||
//! \brief The crash report was uploaded successfully.
|
||||
@@ -117,7 +117,7 @@ class CrashReportUploadThread : public WorkerThread::Delegate {
|
||||
@@ -127,7 +127,7 @@ class CrashReportUploadThread : public WorkerThread::Delegate {
|
||||
//! object was constructed with \a watch_pending_reports, it will also scan
|
||||
//! the crash report database for other pending reports, and process those as
|
||||
//! well.
|
||||
@@ -167,7 +198,7 @@ index c769efed5c54..daec6cd17f37 100644
|
||||
|
||||
//! \brief Processes a single pending report from the database.
|
||||
//!
|
||||
@@ -131,7 +131,7 @@ class CrashReportUploadThread : public WorkerThread::Delegate {
|
||||
@@ -141,7 +141,7 @@ class CrashReportUploadThread : public WorkerThread::Delegate {
|
||||
//! remain in the “pending” state. If the upload fails and no more retries are
|
||||
//! desired, or report upload is disabled, it will be marked as “completed” in
|
||||
//! the database without ever having been uploaded.
|
||||
@@ -177,7 +208,7 @@ index c769efed5c54..daec6cd17f37 100644
|
||||
//! \brief Attempts to upload a crash report.
|
||||
//!
|
||||
diff --git third_party/crashpad/crashpad/handler/handler_main.cc third_party/crashpad/crashpad/handler/handler_main.cc
|
||||
index abc22bf3ef0c..05753af3c2a1 100644
|
||||
index 2e46f86a6522..faf4f1072ad0 100644
|
||||
--- third_party/crashpad/crashpad/handler/handler_main.cc
|
||||
+++ third_party/crashpad/crashpad/handler/handler_main.cc
|
||||
@@ -35,8 +35,10 @@
|
||||
@@ -202,7 +233,7 @@ index abc22bf3ef0c..05753af3c2a1 100644
|
||||
namespace crashpad {
|
||||
|
||||
namespace {
|
||||
@@ -147,6 +153,9 @@ struct Options {
|
||||
@@ -151,6 +157,9 @@ struct Options {
|
||||
bool periodic_tasks;
|
||||
bool rate_limit;
|
||||
bool upload_gzip;
|
||||
@@ -212,7 +243,7 @@ index abc22bf3ef0c..05753af3c2a1 100644
|
||||
};
|
||||
|
||||
// Splits |key_value| on '=' and inserts the resulting key and value into |map|.
|
||||
@@ -430,6 +439,9 @@ int HandlerMain(int argc,
|
||||
@@ -438,6 +447,9 @@ int HandlerMain(int argc,
|
||||
kOptionResetOwnCrashExceptionPortToSystemDefault,
|
||||
#endif // OS_MACOSX
|
||||
kOptionURL,
|
||||
@@ -222,7 +253,7 @@ index abc22bf3ef0c..05753af3c2a1 100644
|
||||
|
||||
// Standard options.
|
||||
kOptionHelp = -2,
|
||||
@@ -476,6 +488,9 @@ int HandlerMain(int argc,
|
||||
@@ -488,6 +500,9 @@ int HandlerMain(int argc,
|
||||
{"url", required_argument, nullptr, kOptionURL},
|
||||
{"help", no_argument, nullptr, kOptionHelp},
|
||||
{"version", no_argument, nullptr, kOptionVersion},
|
||||
@@ -232,7 +263,7 @@ index abc22bf3ef0c..05753af3c2a1 100644
|
||||
{nullptr, 0, nullptr, 0},
|
||||
};
|
||||
|
||||
@@ -575,6 +590,27 @@ int HandlerMain(int argc,
|
||||
@@ -592,6 +607,27 @@ int HandlerMain(int argc,
|
||||
options.url = optarg;
|
||||
break;
|
||||
}
|
||||
@@ -260,23 +291,19 @@ index abc22bf3ef0c..05753af3c2a1 100644
|
||||
case kOptionHelp: {
|
||||
Usage(me);
|
||||
MetricsRecordExit(Metrics::LifetimeMilestone::kExitedEarly);
|
||||
@@ -734,17 +770,27 @@ int HandlerMain(int argc,
|
||||
// TODO(scottmg): options.rate_limit should be removed when we have a
|
||||
// configurable database setting to control upload limiting.
|
||||
// See https://crashpad.chromium.org/bug/23.
|
||||
@@ -757,15 +793,23 @@ int HandlerMain(int argc,
|
||||
upload_thread_options.rate_limit = options.rate_limit;
|
||||
upload_thread_options.upload_gzip = options.upload_gzip;
|
||||
upload_thread_options.watch_pending_reports = options.periodic_tasks;
|
||||
+#if BUILDFLAG(ENABLE_CEF)
|
||||
+ CefCrashReportUploadThread upload_thread(database.get(),
|
||||
+ options.url,
|
||||
+ options.periodic_tasks,
|
||||
+ options.rate_limit,
|
||||
+ options.upload_gzip,
|
||||
+ upload_thread_options,
|
||||
+ options.max_uploads);
|
||||
+#else
|
||||
CrashReportUploadThread upload_thread(database.get(),
|
||||
options.url,
|
||||
options.periodic_tasks,
|
||||
options.rate_limit,
|
||||
options.upload_gzip);
|
||||
upload_thread_options);
|
||||
+#endif
|
||||
upload_thread.Start();
|
||||
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git content/browser/frame_host/render_frame_host_manager.cc content/browser/frame_host/render_frame_host_manager.cc
|
||||
index 7e444585731f..2355ab4fec2b 100644
|
||||
index 0663535e3f81..e0e20722c820 100644
|
||||
--- content/browser/frame_host/render_frame_host_manager.cc
|
||||
+++ content/browser/frame_host/render_frame_host_manager.cc
|
||||
@@ -1072,10 +1072,11 @@ bool RenderFrameHostManager::ShouldSwapBrowsingInstancesForNavigation(
|
||||
@@ -1082,10 +1082,11 @@ bool RenderFrameHostManager::ShouldSwapBrowsingInstancesForNavigation(
|
||||
// TODO(alexmos): This check should've been enforced earlier in the
|
||||
// navigation, in chrome::Navigate(). Verify this, and then convert this to
|
||||
// a CHECK and remove the fallback.
|
||||
@@ -18,7 +18,7 @@ index 7e444585731f..2355ab4fec2b 100644
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -1214,7 +1215,8 @@ RenderFrameHostManager::GetSiteInstanceForNavigation(
|
||||
@@ -1224,7 +1225,8 @@ RenderFrameHostManager::GetSiteInstanceForNavigation(
|
||||
|
||||
// Double-check that the new SiteInstance is associated with the right
|
||||
// BrowserContext.
|
||||
@@ -29,10 +29,10 @@ index 7e444585731f..2355ab4fec2b 100644
|
||||
// If |new_instance| is a new SiteInstance for a subframe with an isolated
|
||||
// origin, set its process reuse policy so that such subframes are
|
||||
diff --git content/public/browser/content_browser_client.h content/public/browser/content_browser_client.h
|
||||
index 842557d5fcb7..fc254e2b7bb8 100644
|
||||
index e56b320170df..26aa6fe50311 100644
|
||||
--- content/public/browser/content_browser_client.h
|
||||
+++ content/public/browser/content_browser_client.h
|
||||
@@ -325,6 +325,13 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
@@ -343,6 +343,13 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
const GURL& current_url,
|
||||
const GURL& new_url);
|
||||
|
||||
@@ -117,10 +117,10 @@ index e85940e1123a..7d4e3c13204b 100644
|
||||
ExtensionRegistry::Get(browser_context_)->RemoveObserver(this);
|
||||
|
||||
diff --git extensions/browser/extension_host.h extensions/browser/extension_host.h
|
||||
index fea09edc247f..16f81b139476 100644
|
||||
index 34812c083bf5..1ccfaf6e1c45 100644
|
||||
--- extensions/browser/extension_host.h
|
||||
+++ extensions/browser/extension_host.h
|
||||
@@ -51,11 +51,17 @@ class ExtensionHost : public DeferredStartRenderHost,
|
||||
@@ -51,13 +51,19 @@ class ExtensionHost : public DeferredStartRenderHost,
|
||||
ExtensionHost(const Extension* extension,
|
||||
content::SiteInstance* site_instance,
|
||||
const GURL& url, ViewType host_type);
|
||||
@@ -132,14 +132,16 @@ index fea09edc247f..16f81b139476 100644
|
||||
+ ViewType host_type);
|
||||
~ExtensionHost() override;
|
||||
|
||||
// This may be null if the extension has been or is being unloaded.
|
||||
const Extension* extension() const { return extension_; }
|
||||
|
||||
const std::string& extension_id() const { return extension_id_; }
|
||||
- content::WebContents* host_contents() const { return host_contents_.get(); }
|
||||
+ content::WebContents* host_contents() const { return host_contents_; }
|
||||
content::RenderViewHost* render_view_host() const;
|
||||
content::RenderProcessHost* render_process_host() const;
|
||||
bool has_loaded_once() const { return has_loaded_once_; }
|
||||
@@ -173,7 +179,8 @@ class ExtensionHost : public DeferredStartRenderHost,
|
||||
@@ -175,7 +181,8 @@ class ExtensionHost : public DeferredStartRenderHost,
|
||||
content::BrowserContext* browser_context_;
|
||||
|
||||
// The host for our HTML content.
|
||||
@@ -150,18 +152,10 @@ index fea09edc247f..16f81b139476 100644
|
||||
// A weak pointer to the current or pending RenderViewHost. We don't access
|
||||
// this through the host_contents because we want to deal with the pending
|
||||
diff --git extensions/browser/extensions_browser_client.h extensions/browser/extensions_browser_client.h
|
||||
index 0c70794823d3..4922df0d5398 100644
|
||||
index 69434c704f2f..f31b65fcd192 100644
|
||||
--- extensions/browser/extensions_browser_client.h
|
||||
+++ extensions/browser/extensions_browser_client.h
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "services/service_manager/public/cpp/binder_registry.h"
|
||||
|
||||
class ExtensionFunctionRegistry;
|
||||
+class GURL;
|
||||
class PrefService;
|
||||
|
||||
namespace base {
|
||||
@@ -49,6 +50,7 @@ class ComponentExtensionResourceManager;
|
||||
@@ -53,6 +53,7 @@ class ComponentExtensionResourceManager;
|
||||
class Extension;
|
||||
class ExtensionCache;
|
||||
class ExtensionError;
|
||||
@@ -169,7 +163,7 @@ index 0c70794823d3..4922df0d5398 100644
|
||||
class ExtensionHostDelegate;
|
||||
class ExtensionPrefsObserver;
|
||||
class ExtensionApiFrameIdMap;
|
||||
@@ -103,6 +105,11 @@ class ExtensionsBrowserClient {
|
||||
@@ -108,6 +109,11 @@ class ExtensionsBrowserClient {
|
||||
virtual content::BrowserContext* GetOriginalContext(
|
||||
content::BrowserContext* context) = 0;
|
||||
|
||||
@@ -181,7 +175,7 @@ index 0c70794823d3..4922df0d5398 100644
|
||||
#if defined(OS_CHROMEOS)
|
||||
// Returns a user id hash from |context| or an empty string if no hash could
|
||||
// be extracted.
|
||||
@@ -163,6 +170,14 @@ class ExtensionsBrowserClient {
|
||||
@@ -173,6 +179,14 @@ class ExtensionsBrowserClient {
|
||||
virtual std::unique_ptr<ExtensionHostDelegate>
|
||||
CreateExtensionHostDelegate() = 0;
|
||||
|
||||
@@ -197,7 +191,7 @@ index 0c70794823d3..4922df0d5398 100644
|
||||
// once each time the extensions system is loaded per browser_context. The
|
||||
// implementation may wish to use the BrowserContext to record the current
|
||||
diff --git extensions/browser/process_manager.cc extensions/browser/process_manager.cc
|
||||
index 383b13c51e08..b3cde7df636a 100644
|
||||
index 5a06db3d4495..b960853f02b2 100644
|
||||
--- extensions/browser/process_manager.cc
|
||||
+++ extensions/browser/process_manager.cc
|
||||
@@ -349,9 +349,16 @@ bool ProcessManager::CreateBackgroundHost(const Extension* extension,
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git .gn .gn
|
||||
index 7a7160de63c1..2b715af702dc 100644
|
||||
index db85e5f4092f..779c93c07523 100644
|
||||
--- .gn
|
||||
+++ .gn
|
||||
@@ -221,6 +221,8 @@ exec_script_whitelist =
|
||||
@@ -230,6 +230,8 @@ exec_script_whitelist =
|
||||
# in the Chromium repo outside of //build.
|
||||
"//build_overrides/build.gni",
|
||||
|
||||
@@ -12,7 +12,7 @@ index 7a7160de63c1..2b715af702dc 100644
|
||||
# https://crbug.com/474506.
|
||||
"//clank/java/BUILD.gn",
|
||||
diff --git BUILD.gn BUILD.gn
|
||||
index df54a97736bd..6a2938a28f8c 100644
|
||||
index 5c26c723bf8b..fa4994456865 100644
|
||||
--- BUILD.gn
|
||||
+++ BUILD.gn
|
||||
@@ -179,6 +179,7 @@ group("gn_all") {
|
||||
@@ -56,7 +56,7 @@ index 982fbe8d3f0d..e757be4688f1 100644
|
||||
+ "studio path")
|
||||
}
|
||||
diff --git build/toolchain/win/setup_toolchain.py build/toolchain/win/setup_toolchain.py
|
||||
index bb599d62968f..410c888cbe54 100644
|
||||
index a1d2ea4b2394..50514a54e64f 100644
|
||||
--- build/toolchain/win/setup_toolchain.py
|
||||
+++ build/toolchain/win/setup_toolchain.py
|
||||
@@ -132,19 +132,22 @@ def _LoadToolchainEnv(cpu, sdk_dir):
|
||||
@@ -96,7 +96,7 @@ index bb599d62968f..410c888cbe54 100644
|
||||
|
||||
|
||||
diff --git build/vs_toolchain.py build/vs_toolchain.py
|
||||
index 7626880b142a..009eab551c90 100755
|
||||
index 7a258ed1dacc..4165c1f9d07b 100755
|
||||
--- build/vs_toolchain.py
|
||||
+++ build/vs_toolchain.py
|
||||
@@ -81,11 +81,18 @@ def SetEnvironmentAndGetRuntimeDllDirs():
|
||||
@@ -119,10 +119,10 @@ index 7626880b142a..009eab551c90 100755
|
||||
# directory in order to run binaries locally, but they are needed in order
|
||||
# to create isolates or the mini_installer. Copying them to the output
|
||||
diff --git chrome/chrome_paks.gni chrome/chrome_paks.gni
|
||||
index 91dc01d5ca6e..129f0a4db7f0 100644
|
||||
index bd0fc70bb87f..79315464c57b 100644
|
||||
--- chrome/chrome_paks.gni
|
||||
+++ chrome/chrome_paks.gni
|
||||
@@ -250,7 +250,7 @@ template("chrome_paks") {
|
||||
@@ -255,7 +255,7 @@ template("chrome_paks") {
|
||||
}
|
||||
|
||||
input_locales = locales
|
||||
@@ -132,10 +132,10 @@ index 91dc01d5ca6e..129f0a4db7f0 100644
|
||||
if (is_mac) {
|
||||
output_locales = locales_as_mac_outputs
|
||||
diff --git chrome/installer/mini_installer/BUILD.gn chrome/installer/mini_installer/BUILD.gn
|
||||
index cc3782f4a91d..7f0e8aa3f82e 100644
|
||||
index 88a6d8627d51..4a25b5d1b713 100644
|
||||
--- chrome/installer/mini_installer/BUILD.gn
|
||||
+++ chrome/installer/mini_installer/BUILD.gn
|
||||
@@ -131,7 +131,7 @@ template("generate_mini_installer") {
|
||||
@@ -130,7 +130,7 @@ template("generate_mini_installer") {
|
||||
inputs = [
|
||||
"$chrome_dll_file",
|
||||
"$root_out_dir/chrome.exe",
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git tools/gritsettings/resource_ids tools/gritsettings/resource_ids
|
||||
index b0c2f87c10e6..521022553ec9 100644
|
||||
index e95450a1ff2b..5fee0604be15 100644
|
||||
--- tools/gritsettings/resource_ids
|
||||
+++ tools/gritsettings/resource_ids
|
||||
@@ -386,4 +386,11 @@
|
||||
@@ -390,4 +390,11 @@
|
||||
# Please read the header and find the right section above instead.
|
||||
|
||||
# Resource ids starting at 31000 are reserved for projects built on Chromium.
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git build/config/compiler/BUILD.gn build/config/compiler/BUILD.gn
|
||||
index 7888e2f8589d..2b3e8dff4637 100644
|
||||
index fff8488778d7..0443bcace1d4 100644
|
||||
--- build/config/compiler/BUILD.gn
|
||||
+++ build/config/compiler/BUILD.gn
|
||||
@@ -398,7 +398,7 @@ config("compiler") {
|
||||
@@ -399,7 +399,7 @@ config("compiler") {
|
||||
# chromeos binutils has been patched with the fix, so always use icf there.
|
||||
# The bug only affects x86 and x64, so we can still use ICF when targeting
|
||||
# other architectures.
|
||||
@@ -11,3 +11,53 @@ index 7888e2f8589d..2b3e8dff4637 100644
|
||||
!(current_cpu == "x86" || current_cpu == "x64")) {
|
||||
ldflags += [ "-Wl,--icf=all" ]
|
||||
}
|
||||
diff --git chrome/browser/ui/libgtkui/gtk_ui.cc chrome/browser/ui/libgtkui/gtk_ui.cc
|
||||
index bf37dd5c3799..ad5693e38487 100644
|
||||
--- chrome/browser/ui/libgtkui/gtk_ui.cc
|
||||
+++ chrome/browser/ui/libgtkui/gtk_ui.cc
|
||||
@@ -404,11 +404,13 @@ SkColor GetToolbarTopSeparatorColor(SkColor header_fg,
|
||||
}
|
||||
#endif
|
||||
|
||||
+#if GTK_MAJOR_VERSION >= 3
|
||||
using GdkSetAllowedBackendsFn = void (*)(const gchar*);
|
||||
// Place this function pointers in read-only memory after being resolved to
|
||||
// prevent it being tampered with. See crbug.com/771365 for details.
|
||||
PROTECTED_MEMORY_SECTION base::ProtectedMemory<GdkSetAllowedBackendsFn>
|
||||
g_gdk_set_allowed_backends;
|
||||
+#endif
|
||||
|
||||
} // namespace
|
||||
|
||||
diff --git chrome/browser/ui/libgtkui/native_theme_gtk2.cc chrome/browser/ui/libgtkui/native_theme_gtk2.cc
|
||||
index af67e8343f5a..1e6d1e5818e4 100644
|
||||
--- chrome/browser/ui/libgtkui/native_theme_gtk2.cc
|
||||
+++ chrome/browser/ui/libgtkui/native_theme_gtk2.cc
|
||||
@@ -348,6 +348,7 @@ SkColor NativeThemeGtk2::GetSystemColor(ColorId color_id) const {
|
||||
}
|
||||
|
||||
case kColorId_NumColors:
|
||||
+ default:
|
||||
NOTREACHED();
|
||||
break;
|
||||
}
|
||||
diff --git ui/accessibility/platform/atk_util_auralinux_gtk2.cc ui/accessibility/platform/atk_util_auralinux_gtk2.cc
|
||||
index 9c50ead85605..54cbd52c7de0 100644
|
||||
--- ui/accessibility/platform/atk_util_auralinux_gtk2.cc
|
||||
+++ ui/accessibility/platform/atk_util_auralinux_gtk2.cc
|
||||
@@ -56,6 +56,8 @@ void FinishAccessibilityInitOnMainThread(
|
||||
init_func();
|
||||
}
|
||||
|
||||
+namespace ui {
|
||||
+
|
||||
bool AtkUtilAuraLinux::PlatformShouldEnableAccessibility() {
|
||||
std::unique_ptr<base::Environment> env(base::Environment::Create());
|
||||
std::string gtk_modules;
|
||||
@@ -78,3 +80,6 @@ void AtkUtilAuraLinux::PlatformInitializeAsync() {
|
||||
base::Bind(&GetAccessibilityModuleInitFunc),
|
||||
base::Bind(&FinishAccessibilityInitOnMainThread));
|
||||
}
|
||||
+
|
||||
+} // namespace ui
|
||||
+
|
||||
|
@@ -1,19 +1,13 @@
|
||||
diff --git third_party/widevine/cdm/BUILD.gn third_party/widevine/cdm/BUILD.gn
|
||||
index a3eac59cc2eb..d14e71e0319b 100644
|
||||
index f35d81872096..d14e71e0319b 100644
|
||||
--- third_party/widevine/cdm/BUILD.gn
|
||||
+++ third_party/widevine/cdm/BUILD.gn
|
||||
@@ -111,14 +111,8 @@ if (widevine_cdm_binary_files != []) {
|
||||
@@ -110,7 +110,9 @@ if (widevine_cdm_binary_files != []) {
|
||||
"//build/config:exe_and_shlib_deps",
|
||||
]
|
||||
|
||||
if (is_mac) {
|
||||
- ldflags = [
|
||||
- # Not to strip important symbols by -Wl,-dead_strip.
|
||||
- "-Wl,-exported_symbol,_PPP_GetInterface",
|
||||
- "-Wl,-exported_symbol,_PPP_InitializeModule",
|
||||
- "-Wl,-exported_symbol,_PPP_ShutdownModule",
|
||||
- ]
|
||||
- #TODO(jrummell) Mac: 'DYLIB_INSTALL_NAME_BASE': '@loader_path',
|
||||
- } else if (is_posix && !is_mac) {
|
||||
- if (is_posix && !is_mac) {
|
||||
+ if (is_mac) {
|
||||
+ ldflags = [ "-Wl,-install_name,@loader_path/libwidevinecdm.dylib" ]
|
||||
+ } else if (is_posix) {
|
||||
cflags = [ "-fvisibility=hidden" ]
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git base/message_loop/message_loop.h base/message_loop/message_loop.h
|
||||
index 0c82e51dfcd4..e5cb6fdb4c80 100644
|
||||
index bff60ef11025..33b430dadaf7 100644
|
||||
--- base/message_loop/message_loop.h
|
||||
+++ base/message_loop/message_loop.h
|
||||
@@ -277,6 +277,16 @@ class BASE_EXPORT MessageLoop : public MessagePump::Delegate,
|
||||
@@ -266,6 +266,16 @@ class BASE_EXPORT MessageLoop : public MessagePump::Delegate,
|
||||
void AddTaskObserver(TaskObserver* task_observer);
|
||||
void RemoveTaskObserver(TaskObserver* task_observer);
|
||||
|
||||
@@ -19,9 +19,9 @@ index 0c82e51dfcd4..e5cb6fdb4c80 100644
|
||||
// Returns true if the message loop is "idle". Provided for testing.
|
||||
bool IsIdleForTesting();
|
||||
|
||||
@@ -376,6 +386,12 @@ class BASE_EXPORT MessageLoop : public MessagePump::Delegate,
|
||||
// need to be checked in conditionals).
|
||||
bool nestable_tasks_allowed_;
|
||||
@@ -369,6 +379,12 @@ class BASE_EXPORT MessageLoop : public MessagePump::Delegate,
|
||||
// is known to generate a system-driven nested loop.
|
||||
bool task_execution_allowed_ = true;
|
||||
|
||||
+#if defined(OS_WIN)
|
||||
+ // Should be set to true before calling Windows APIs like TrackPopupMenu, etc.
|
||||
|
@@ -1,5 +1,5 @@
|
||||
diff --git net/base/network_delegate.h net/base/network_delegate.h
|
||||
index 22d22d03554a..c9a1c6df8f1b 100644
|
||||
index 22c428f90b16..1e0e6deaa7df 100644
|
||||
--- net/base/network_delegate.h
|
||||
+++ net/base/network_delegate.h
|
||||
@@ -16,6 +16,7 @@
|
||||
@@ -22,10 +22,10 @@ index 22d22d03554a..c9a1c6df8f1b 100644
|
||||
THREAD_CHECKER(thread_checker_);
|
||||
|
||||
diff --git net/url_request/url_request_job.cc net/url_request/url_request_job.cc
|
||||
index d9719f0bb720..2a798690a932 100644
|
||||
index 25e971d7e6bc..2d14710ed4fe 100644
|
||||
--- net/url_request/url_request_job.cc
|
||||
+++ net/url_request/url_request_job.cc
|
||||
@@ -442,6 +442,12 @@ void URLRequestJob::NotifyHeadersComplete() {
|
||||
@@ -447,6 +447,12 @@ void URLRequestJob::NotifyHeadersComplete() {
|
||||
DCHECK(!source_stream_);
|
||||
source_stream_ = SetUpSourceStream();
|
||||
|
||||
|
@@ -1,5 +1,5 @@
|
||||
diff --git net/cert/ct_policy_enforcer.cc net/cert/ct_policy_enforcer.cc
|
||||
index 61d169cb5bfa..6e16906c7cc2 100644
|
||||
index 0f7778089273..40111e89a2e0 100644
|
||||
--- net/cert/ct_policy_enforcer.cc
|
||||
+++ net/cert/ct_policy_enforcer.cc
|
||||
@@ -35,15 +35,6 @@ namespace net {
|
||||
@@ -18,7 +18,7 @@ index 61d169cb5bfa..6e16906c7cc2 100644
|
||||
// Returns a rounded-down months difference of |start| and |end|,
|
||||
// together with an indication of whether the last month was
|
||||
// a full month, because the range starts specified in the policy
|
||||
@@ -301,4 +292,13 @@ ct::CertPolicyCompliance CTPolicyEnforcer::DoesConformToCertPolicy(
|
||||
@@ -302,4 +293,13 @@ ct::CTPolicyCompliance CTPolicyEnforcer::CheckCompliance(
|
||||
return compliance;
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ index 61d169cb5bfa..6e16906c7cc2 100644
|
||||
+
|
||||
} // namespace net
|
||||
diff --git net/cert/ct_policy_enforcer.h net/cert/ct_policy_enforcer.h
|
||||
index b594cba1a6fc..285eae814c50 100644
|
||||
index fb6f4847cfe9..aa4c1cdafb9f 100644
|
||||
--- net/cert/ct_policy_enforcer.h
|
||||
+++ net/cert/ct_policy_enforcer.h
|
||||
@@ -42,6 +42,17 @@ class NET_EXPORT CTPolicyEnforcer {
|
||||
@@ -55,10 +55,10 @@ index b594cba1a6fc..285eae814c50 100644
|
||||
|
||||
} // namespace net
|
||||
diff --git net/http/transport_security_state.cc net/http/transport_security_state.cc
|
||||
index 5af15d92ef49..f459c4355860 100644
|
||||
index a433afd02178..ff92489ed243 100644
|
||||
--- net/http/transport_security_state.cc
|
||||
+++ net/http/transport_security_state.cc
|
||||
@@ -1541,8 +1541,10 @@ void TransportSecurityState::ClearReportCachesForTesting() {
|
||||
@@ -1553,8 +1553,10 @@ void TransportSecurityState::ClearReportCachesForTesting() {
|
||||
sent_expect_ct_reports_cache_.Clear();
|
||||
}
|
||||
|
||||
@@ -72,10 +72,10 @@ index 5af15d92ef49..f459c4355860 100644
|
||||
// We consider built-in information to be timely for 10 weeks.
|
||||
return (base::Time::Now() - build_time).InDays() < 70 /* 10 weeks */;
|
||||
diff --git net/http/transport_security_state.h net/http/transport_security_state.h
|
||||
index b4bab0db79db..6c11351b43ba 100644
|
||||
index 79d3a1c3453f..d97e26b4b024 100644
|
||||
--- net/http/transport_security_state.h
|
||||
+++ net/http/transport_security_state.h
|
||||
@@ -574,6 +574,10 @@ class NET_EXPORT TransportSecurityState {
|
||||
@@ -576,6 +576,10 @@ class NET_EXPORT TransportSecurityState {
|
||||
// Expect-CT reports.
|
||||
void ClearReportCachesForTesting();
|
||||
|
||||
@@ -86,7 +86,7 @@ index b4bab0db79db..6c11351b43ba 100644
|
||||
private:
|
||||
friend class TransportSecurityStateTest;
|
||||
friend class TransportSecurityStateStaticFuzzer;
|
||||
@@ -594,7 +598,7 @@ class NET_EXPORT TransportSecurityState {
|
||||
@@ -596,7 +600,7 @@ class NET_EXPORT TransportSecurityState {
|
||||
// IsBuildTimely returns true if the current build is new enough ensure that
|
||||
// built in security information (i.e. HSTS preloading and pinning
|
||||
// information) is timely.
|
||||
@@ -95,7 +95,7 @@ index b4bab0db79db..6c11351b43ba 100644
|
||||
|
||||
// Helper method for actually checking pins.
|
||||
PKPStatus CheckPublicKeyPinsImpl(
|
||||
@@ -703,6 +707,8 @@ class NET_EXPORT TransportSecurityState {
|
||||
@@ -705,6 +709,8 @@ class NET_EXPORT TransportSecurityState {
|
||||
// True if public key pinning bypass is enabled for local trust anchors.
|
||||
bool enable_pkp_bypass_for_local_trust_anchors_;
|
||||
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git net/url_request/url_request.h net/url_request/url_request.h
|
||||
index 378fe780f11d..2a9b37b3ad8d 100644
|
||||
index 0635448f00a1..3d91e1d92d7f 100644
|
||||
--- net/url_request/url_request.h
|
||||
+++ net/url_request/url_request.h
|
||||
@@ -681,10 +681,10 @@ class NET_EXPORT URLRequest : public base::SupportsUserData {
|
||||
@@ -684,10 +684,10 @@ class NET_EXPORT URLRequest : public base::SupportsUserData {
|
||||
// called with a response from the server.
|
||||
void SetResponseHeadersCallback(ResponseHeadersCallback callback);
|
||||
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git BUILD.gn BUILD.gn
|
||||
index 3e3f22fdd..b5c2e5265 100644
|
||||
index 6fb2bd888..b275bfd2b 100644
|
||||
--- BUILD.gn
|
||||
+++ BUILD.gn
|
||||
@@ -227,6 +227,10 @@ static_library("pdfium") {
|
||||
@@ -229,6 +229,10 @@ static_library("pdfium") {
|
||||
if (pdf_is_complete_lib) {
|
||||
complete_static_lib = true
|
||||
}
|
||||
@@ -14,18 +14,18 @@ index 3e3f22fdd..b5c2e5265 100644
|
||||
|
||||
static_library("test_support") {
|
||||
diff --git fpdfsdk/fpdfview.cpp fpdfsdk/fpdfview.cpp
|
||||
index af1d0db1a..9b0397391 100644
|
||||
index 2736b8dd6..830f074b7 100644
|
||||
--- fpdfsdk/fpdfview.cpp
|
||||
+++ fpdfsdk/fpdfview.cpp
|
||||
@@ -37,6 +37,7 @@
|
||||
@@ -36,6 +36,7 @@
|
||||
#include "fpdfsdk/cpdfsdk_pageview.h"
|
||||
#include "fpdfsdk/fsdk_define.h"
|
||||
#include "fpdfsdk/fsdk_pauseadapter.h"
|
||||
#include "fpdfsdk/javascript/ijs_runtime.h"
|
||||
+#include "fxjs/fxjs_v8.h"
|
||||
#include "fxjs/ijs_runtime.h"
|
||||
#include "public/fpdf_edit.h"
|
||||
#include "public/fpdf_ext.h"
|
||||
#include "public/fpdf_progressive.h"
|
||||
@@ -486,6 +487,7 @@ FPDF_EXPORT void FPDF_CALLCONV FPDF_DestroyLibrary() {
|
||||
@@ -497,6 +498,7 @@ FPDF_EXPORT void FPDF_CALLCONV FPDF_DestroyLibrary() {
|
||||
|
||||
CPDF_ModuleMgr::Destroy();
|
||||
CFX_GEModule::Destroy();
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git content/public/common/common_param_traits_macros.h content/public/common/common_param_traits_macros.h
|
||||
index 90951a5d5e56..940fe86b6587 100644
|
||||
index 63a73ad504d5..9b8cde03ecf4 100644
|
||||
--- content/public/common/common_param_traits_macros.h
|
||||
+++ content/public/common/common_param_traits_macros.h
|
||||
@@ -208,6 +208,7 @@ IPC_STRUCT_TRAITS_BEGIN(content::WebPreferences)
|
||||
@@ -195,6 +195,7 @@ IPC_STRUCT_TRAITS_BEGIN(content::WebPreferences)
|
||||
IPC_STRUCT_TRAITS_MEMBER(main_frame_resizes_are_orientation_changes)
|
||||
IPC_STRUCT_TRAITS_MEMBER(initialize_at_minimum_page_scale)
|
||||
IPC_STRUCT_TRAITS_MEMBER(smart_insert_delete_enabled)
|
||||
@@ -11,10 +11,10 @@ index 90951a5d5e56..940fe86b6587 100644
|
||||
IPC_STRUCT_TRAITS_MEMBER(navigate_on_drag_drop)
|
||||
IPC_STRUCT_TRAITS_MEMBER(spatial_navigation_enabled)
|
||||
diff --git content/public/common/web_preferences.cc content/public/common/web_preferences.cc
|
||||
index 722afb30f662..42274dd9cc8c 100644
|
||||
index cc20936125f4..a1cde3a9a2b2 100644
|
||||
--- content/public/common/web_preferences.cc
|
||||
+++ content/public/common/web_preferences.cc
|
||||
@@ -179,6 +179,7 @@ WebPreferences::WebPreferences()
|
||||
@@ -178,6 +178,7 @@ WebPreferences::WebPreferences()
|
||||
spatial_navigation_enabled(false),
|
||||
use_solid_color_scrollbars(false),
|
||||
navigate_on_drag_drop(true),
|
||||
@@ -23,10 +23,10 @@ index 722afb30f662..42274dd9cc8c 100644
|
||||
record_whole_document(false),
|
||||
save_previous_document_resources(SavePreviousDocumentResources::NEVER),
|
||||
diff --git content/public/common/web_preferences.h content/public/common/web_preferences.h
|
||||
index c81979993ad5..f0a4474c4023 100644
|
||||
index 361505babff0..341873d000bc 100644
|
||||
--- content/public/common/web_preferences.h
|
||||
+++ content/public/common/web_preferences.h
|
||||
@@ -198,6 +198,7 @@ struct CONTENT_EXPORT WebPreferences {
|
||||
@@ -197,6 +197,7 @@ struct CONTENT_EXPORT WebPreferences {
|
||||
bool spatial_navigation_enabled;
|
||||
bool use_solid_color_scrollbars;
|
||||
bool navigate_on_drag_drop;
|
||||
@@ -35,10 +35,10 @@ index c81979993ad5..f0a4474c4023 100644
|
||||
bool record_whole_document;
|
||||
SavePreviousDocumentResources save_previous_document_resources;
|
||||
diff --git content/renderer/render_view_impl.cc content/renderer/render_view_impl.cc
|
||||
index 22bd13a28fb7..027eaf5b65da 100644
|
||||
index 0f5f1d8e1649..ae5c98646619 100644
|
||||
--- content/renderer/render_view_impl.cc
|
||||
+++ content/renderer/render_view_impl.cc
|
||||
@@ -1308,6 +1308,8 @@ void RenderViewImpl::ApplyWebPreferencesInternal(
|
||||
@@ -1250,6 +1250,8 @@ void RenderViewImpl::ApplyWebPreferencesInternal(
|
||||
blink::WebView* web_view,
|
||||
CompositorDependencies* compositor_deps) {
|
||||
ApplyWebPreferences(prefs, web_view);
|
||||
|
@@ -1,34 +1,44 @@
|
||||
diff --git chrome/browser/ui/BUILD.gn chrome/browser/ui/BUILD.gn
|
||||
index 02b2c4212767..5a89d17b06a4 100644
|
||||
--- chrome/browser/ui/BUILD.gn
|
||||
+++ chrome/browser/ui/BUILD.gn
|
||||
@@ -344,6 +344,7 @@ split_static_library("ui") {
|
||||
"//base:i18n",
|
||||
"//base/allocator:features",
|
||||
"//cc/paint",
|
||||
+ "//cef/libcef/features",
|
||||
"//chrome:extra_resources",
|
||||
"//chrome:resources",
|
||||
"//chrome:strings",
|
||||
diff --git chrome/browser/ui/cocoa/applescript/tab_applescript.mm chrome/browser/ui/cocoa/applescript/tab_applescript.mm
|
||||
index 0cd84f38c229..2f872dd3dfe2 100644
|
||||
index e5ac419b8f4c..ced62e390bc4 100644
|
||||
--- chrome/browser/ui/cocoa/applescript/tab_applescript.mm
|
||||
+++ chrome/browser/ui/cocoa/applescript/tab_applescript.mm
|
||||
@@ -9,7 +9,6 @@
|
||||
@@ -9,7 +9,7 @@
|
||||
#include "base/logging.h"
|
||||
#import "base/mac/scoped_nsobject.h"
|
||||
#include "base/strings/sys_string_conversions.h"
|
||||
-#include "chrome/browser/printing/print_view_manager.h"
|
||||
+#include "cef/libcef/features/features.h"
|
||||
#include "chrome/browser/profiles/profile.h"
|
||||
#include "chrome/browser/sessions/session_tab_helper.h"
|
||||
#include "chrome/browser/ui/cocoa/applescript/apple_event_util.h"
|
||||
#include "chrome/browser/ui/cocoa/applescript/error_applescript.h"
|
||||
@@ -25,8 +24,13 @@
|
||||
#include "content/public/browser/save_page_type.h"
|
||||
#include "content/public/browser/web_contents.h"
|
||||
@@ -27,6 +27,10 @@
|
||||
#include "content/public/browser/web_contents_delegate.h"
|
||||
+#include "printing/features/features.h"
|
||||
#include "url/gurl.h"
|
||||
|
||||
+#if BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
+#if !BUILDFLAG(ENABLE_CEF)
|
||||
+#include "chrome/browser/printing/print_view_manager.h"
|
||||
+#endif
|
||||
+
|
||||
using content::NavigationController;
|
||||
using content::NavigationEntry;
|
||||
using content::OpenURLParams;
|
||||
@@ -231,11 +235,15 @@ void ResumeAppleEventAndSendReply(NSAppleEventManagerSuspensionID suspension_id,
|
||||
@@ -232,11 +236,15 @@ void ResumeAppleEventAndSendReply(NSAppleEventManagerSuspensionID suspension_id,
|
||||
|
||||
- (void)handlesPrintScriptCommand:(NSScriptCommand*)command {
|
||||
AppleScript::LogAppleScriptUMA(AppleScript::AppleScriptCommand::TAB_PRINT);
|
||||
+#if BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
+#if !BUILDFLAG(ENABLE_CEF)
|
||||
bool initiated = printing::PrintViewManager::FromWebContents(webContents_)
|
||||
->PrintNow(webContents_->GetMainFrame());
|
||||
if (!initiated) {
|
||||
@@ -40,11 +50,42 @@ index 0cd84f38c229..2f872dd3dfe2 100644
|
||||
}
|
||||
|
||||
- (void)handlesSaveScriptCommand:(NSScriptCommand*)command {
|
||||
diff --git chrome/browser/ui/webui/settings/printing_handler.cc chrome/browser/ui/webui/settings/printing_handler.cc
|
||||
index 45644030eb24..c894209e1530 100644
|
||||
--- chrome/browser/ui/webui/settings/printing_handler.cc
|
||||
+++ chrome/browser/ui/webui/settings/printing_handler.cc
|
||||
@@ -6,9 +6,13 @@
|
||||
|
||||
#include "base/bind.h"
|
||||
#include "base/bind_helpers.h"
|
||||
-#include "chrome/browser/printing/printer_manager_dialog.h"
|
||||
+#include "cef/libcef/features/features.h"
|
||||
#include "content/public/browser/web_ui.h"
|
||||
|
||||
+#if !BUILDFLAG(ENABLE_CEF)
|
||||
+#include "chrome/browser/printing/printer_manager_dialog.h"
|
||||
+#endif
|
||||
+
|
||||
namespace settings {
|
||||
|
||||
PrintingHandler::PrintingHandler() {}
|
||||
@@ -27,7 +31,11 @@ void PrintingHandler::OnJavascriptAllowed() {}
|
||||
void PrintingHandler::OnJavascriptDisallowed() {}
|
||||
|
||||
void PrintingHandler::HandleOpenSystemPrintDialog(const base::ListValue* args) {
|
||||
+#if !BUILDFLAG(ENABLE_CEF)
|
||||
printing::PrinterManagerDialog::ShowPrinterManagerDialog();
|
||||
+#else
|
||||
+ NOTIMPLEMENTED();
|
||||
+#endif
|
||||
}
|
||||
|
||||
} // namespace settings
|
||||
diff --git chrome/common/chrome_utility_printing_messages.h chrome/common/chrome_utility_printing_messages.h
|
||||
index fa7702857f75..874a37146fb5 100644
|
||||
index cb6092794c46..2db218d9f140 100644
|
||||
--- chrome/common/chrome_utility_printing_messages.h
|
||||
+++ chrome/common/chrome_utility_printing_messages.h
|
||||
@@ -26,7 +26,6 @@
|
||||
@@ -27,7 +27,6 @@
|
||||
#define IPC_MESSAGE_START ChromeUtilityPrintingMsgStart
|
||||
|
||||
// Preview and Cloud Print messages.
|
||||
@@ -52,7 +93,7 @@ index fa7702857f75..874a37146fb5 100644
|
||||
IPC_ENUM_TRAITS_MAX_VALUE(printing::PdfRenderSettings::Mode,
|
||||
printing::PdfRenderSettings::Mode::LAST)
|
||||
|
||||
@@ -38,6 +37,7 @@ IPC_STRUCT_TRAITS_BEGIN(printing::PdfRenderSettings)
|
||||
@@ -39,6 +38,7 @@ IPC_STRUCT_TRAITS_BEGIN(printing::PdfRenderSettings)
|
||||
IPC_STRUCT_TRAITS_MEMBER(mode)
|
||||
IPC_STRUCT_TRAITS_END()
|
||||
|
||||
@@ -61,10 +102,10 @@ index fa7702857f75..874a37146fb5 100644
|
||||
IPC_STRUCT_TRAITS_MEMBER(printer_capabilities)
|
||||
IPC_STRUCT_TRAITS_MEMBER(caps_mime_type)
|
||||
diff --git components/printing/common/print_messages.cc components/printing/common/print_messages.cc
|
||||
index 6767c4af66ab..c860394ba411 100644
|
||||
index 5ccf87b28860..48e557d84d5e 100644
|
||||
--- components/printing/common/print_messages.cc
|
||||
+++ components/printing/common/print_messages.cc
|
||||
@@ -101,7 +101,6 @@ void PrintMsg_PrintPages_Params::Reset() {
|
||||
@@ -125,7 +125,6 @@ void PrintMsg_PrintPages_Params::Reset() {
|
||||
pages = std::vector<int>();
|
||||
}
|
||||
|
||||
@@ -72,16 +113,16 @@ index 6767c4af66ab..c860394ba411 100644
|
||||
PrintHostMsg_RequestPrintPreview_Params::
|
||||
PrintHostMsg_RequestPrintPreview_Params()
|
||||
: is_modifiable(false),
|
||||
@@ -123,4 +122,3 @@ PrintHostMsg_SetOptionsFromDocument_Params::
|
||||
@@ -147,4 +146,3 @@ PrintHostMsg_SetOptionsFromDocument_Params::
|
||||
PrintHostMsg_SetOptionsFromDocument_Params::
|
||||
~PrintHostMsg_SetOptionsFromDocument_Params() {
|
||||
}
|
||||
-#endif // BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
diff --git components/printing/common/print_messages.h components/printing/common/print_messages.h
|
||||
index ed443d2a8117..a0180ec440f0 100644
|
||||
index 339e63c3294b..75673f2de92f 100644
|
||||
--- components/printing/common/print_messages.h
|
||||
+++ components/printing/common/print_messages.h
|
||||
@@ -76,7 +76,6 @@ struct PrintMsg_PrintPages_Params {
|
||||
@@ -77,7 +77,6 @@ struct PrintMsg_PrintPages_Params {
|
||||
std::vector<int> pages;
|
||||
};
|
||||
|
||||
@@ -89,15 +130,15 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
struct PrintHostMsg_RequestPrintPreview_Params {
|
||||
PrintHostMsg_RequestPrintPreview_Params();
|
||||
~PrintHostMsg_RequestPrintPreview_Params();
|
||||
@@ -95,7 +94,6 @@ struct PrintHostMsg_SetOptionsFromDocument_Params {
|
||||
@@ -96,7 +95,6 @@ struct PrintHostMsg_SetOptionsFromDocument_Params {
|
||||
printing::DuplexMode duplex;
|
||||
printing::PageRanges page_ranges;
|
||||
};
|
||||
-#endif // BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
|
||||
#endif // COMPONENTS_PRINTING_COMMON_PRINT_MESSAGES_H_
|
||||
#endif // INTERNAL_COMPONENTS_PRINTING_COMMON_PRINT_MESSAGES_H_
|
||||
|
||||
@@ -180,7 +178,6 @@ IPC_STRUCT_TRAITS_BEGIN(printing::PageRange)
|
||||
@@ -181,7 +179,6 @@ IPC_STRUCT_TRAITS_BEGIN(printing::PageRange)
|
||||
IPC_STRUCT_TRAITS_MEMBER(to)
|
||||
IPC_STRUCT_TRAITS_END()
|
||||
|
||||
@@ -105,7 +146,7 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
IPC_STRUCT_TRAITS_BEGIN(PrintHostMsg_RequestPrintPreview_Params)
|
||||
IPC_STRUCT_TRAITS_MEMBER(is_modifiable)
|
||||
IPC_STRUCT_TRAITS_MEMBER(webnode_only)
|
||||
@@ -201,7 +198,6 @@ IPC_STRUCT_TRAITS_BEGIN(PrintHostMsg_SetOptionsFromDocument_Params)
|
||||
@@ -202,7 +199,6 @@ IPC_STRUCT_TRAITS_BEGIN(PrintHostMsg_SetOptionsFromDocument_Params)
|
||||
// Specifies page range to be printed.
|
||||
IPC_STRUCT_TRAITS_MEMBER(page_ranges)
|
||||
IPC_STRUCT_TRAITS_END()
|
||||
@@ -113,7 +154,7 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
|
||||
IPC_STRUCT_TRAITS_BEGIN(printing::PageSizeMargins)
|
||||
IPC_STRUCT_TRAITS_MEMBER(content_width)
|
||||
@@ -221,7 +217,6 @@ IPC_STRUCT_TRAITS_BEGIN(PrintMsg_PrintPages_Params)
|
||||
@@ -222,7 +218,6 @@ IPC_STRUCT_TRAITS_BEGIN(PrintMsg_PrintPages_Params)
|
||||
IPC_STRUCT_TRAITS_MEMBER(pages)
|
||||
IPC_STRUCT_TRAITS_END()
|
||||
|
||||
@@ -121,7 +162,7 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
// Parameters to describe a rendered document.
|
||||
IPC_STRUCT_BEGIN(PrintHostMsg_DidPreviewDocument_Params)
|
||||
// A shared memory handle to metafile data.
|
||||
@@ -272,7 +267,6 @@ IPC_STRUCT_BEGIN(PrintHostMsg_DidGetPreviewPageCount_Params)
|
||||
@@ -273,7 +268,6 @@ IPC_STRUCT_BEGIN(PrintHostMsg_DidGetPreviewPageCount_Params)
|
||||
// Indicates whether the existing preview data needs to be cleared or not.
|
||||
IPC_STRUCT_MEMBER(bool, clear_preview_data)
|
||||
IPC_STRUCT_END()
|
||||
@@ -129,7 +170,7 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
|
||||
// Parameters to describe a rendered page.
|
||||
IPC_STRUCT_BEGIN(PrintHostMsg_DidPrintPage_Params)
|
||||
@@ -315,22 +309,20 @@ IPC_STRUCT_END()
|
||||
@@ -316,22 +310,20 @@ IPC_STRUCT_END()
|
||||
|
||||
// Messages sent from the browser to the renderer.
|
||||
|
||||
@@ -154,7 +195,7 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
|
||||
#if BUILDFLAG(ENABLE_BASIC_PRINTING)
|
||||
// Tells the RenderFrame to switch the CSS to print media type, renders every
|
||||
@@ -348,13 +340,13 @@ IPC_MESSAGE_ROUTED1(PrintMsg_PrintingDone,
|
||||
@@ -349,13 +341,13 @@ IPC_MESSAGE_ROUTED1(PrintMsg_PrintingDone,
|
||||
// Tells the RenderFrame whether printing is enabled or not.
|
||||
IPC_MESSAGE_ROUTED1(PrintMsg_SetPrintingEnabled, bool /* enabled */)
|
||||
|
||||
@@ -169,7 +210,7 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
// Tells the RenderFrame that print preview dialog was closed.
|
||||
IPC_MESSAGE_ROUTED0(PrintMsg_ClosePrintPreviewDialog)
|
||||
#endif
|
||||
@@ -414,7 +406,6 @@ IPC_MESSAGE_CONTROL3(PrintHostMsg_TempFileForPrintingWritten,
|
||||
@@ -415,7 +407,6 @@ IPC_MESSAGE_CONTROL3(PrintHostMsg_TempFileForPrintingWritten,
|
||||
int /* page count */)
|
||||
#endif // defined(OS_ANDROID)
|
||||
|
||||
@@ -177,7 +218,7 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
// Asks the browser to do print preview.
|
||||
IPC_MESSAGE_ROUTED1(PrintHostMsg_RequestPrintPreview,
|
||||
PrintHostMsg_RequestPrintPreview_Params /* params */)
|
||||
@@ -448,7 +439,6 @@ IPC_SYNC_MESSAGE_ROUTED2_1(PrintHostMsg_CheckForCancel,
|
||||
@@ -449,7 +440,6 @@ IPC_SYNC_MESSAGE_ROUTED2_1(PrintHostMsg_CheckForCancel,
|
||||
// The memory handle in this message is already valid in the browser process.
|
||||
IPC_MESSAGE_ROUTED1(PrintHostMsg_MetafileReadyForPrinting,
|
||||
PrintHostMsg_DidPreviewDocument_Params /* params */)
|
||||
@@ -185,7 +226,7 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
|
||||
// This is sent when there are invalid printer settings.
|
||||
IPC_MESSAGE_ROUTED0(PrintHostMsg_ShowInvalidPrinterSettingsError)
|
||||
@@ -457,7 +447,6 @@ IPC_MESSAGE_ROUTED0(PrintHostMsg_ShowInvalidPrinterSettingsError)
|
||||
@@ -458,7 +448,6 @@ IPC_MESSAGE_ROUTED0(PrintHostMsg_ShowInvalidPrinterSettingsError)
|
||||
IPC_MESSAGE_ROUTED1(PrintHostMsg_PrintingFailed,
|
||||
int /* document cookie */)
|
||||
|
||||
@@ -193,16 +234,18 @@ index ed443d2a8117..a0180ec440f0 100644
|
||||
// Tell the browser print preview failed.
|
||||
IPC_MESSAGE_ROUTED1(PrintHostMsg_PrintPreviewFailed,
|
||||
int /* document cookie */)
|
||||
@@ -484,4 +473,3 @@ IPC_MESSAGE_ROUTED1(PrintHostMsg_ShowScriptedPrintPreview,
|
||||
@@ -485,6 +474,5 @@ IPC_MESSAGE_ROUTED1(PrintHostMsg_ShowScriptedPrintPreview,
|
||||
// Notify the browser to set print presets based on source PDF document.
|
||||
IPC_MESSAGE_ROUTED1(PrintHostMsg_SetOptionsFromDocument,
|
||||
PrintHostMsg_SetOptionsFromDocument_Params /* params */)
|
||||
-#endif // BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
|
||||
#endif // COMPONENTS_PRINTING_COMMON_PRINT_MESSAGES_H_
|
||||
diff --git components/printing/renderer/print_render_frame_helper.cc components/printing/renderer/print_render_frame_helper.cc
|
||||
index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
index 663cd7748493..588797775ead 100644
|
||||
--- components/printing/renderer/print_render_frame_helper.cc
|
||||
+++ components/printing/renderer/print_render_frame_helper.cc
|
||||
@@ -319,7 +319,6 @@ bool PrintingNodeOrPdfFrame(const blink::WebLocalFrame* frame,
|
||||
@@ -320,7 +320,6 @@ bool PrintingNodeOrPdfFrame(const blink::WebLocalFrame* frame,
|
||||
return plugin && plugin->SupportsPaginatedPrint();
|
||||
}
|
||||
|
||||
@@ -210,7 +253,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
// Returns true if the current destination printer is PRINT_TO_PDF.
|
||||
bool IsPrintToPdfRequested(const base::DictionaryValue& job_settings) {
|
||||
bool print_to_pdf = false;
|
||||
@@ -341,7 +340,6 @@ bool PrintingFrameHasPageSizeStyle(blink::WebLocalFrame* frame,
|
||||
@@ -342,7 +341,6 @@ bool PrintingFrameHasPageSizeStyle(blink::WebLocalFrame* frame,
|
||||
}
|
||||
return frame_has_custom_page_size_style;
|
||||
}
|
||||
@@ -218,7 +261,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
|
||||
#if BUILDFLAG(ENABLE_PRINTING)
|
||||
// Disable scaling when either:
|
||||
@@ -398,7 +396,6 @@ MarginType GetMarginsForPdf(blink::WebLocalFrame* frame,
|
||||
@@ -399,7 +397,6 @@ MarginType GetMarginsForPdf(blink::WebLocalFrame* frame,
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -226,7 +269,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
bool FitToPageEnabled(const base::DictionaryValue& job_settings) {
|
||||
bool fit_to_paper_size = false;
|
||||
if (!job_settings.GetBoolean(kSettingFitToPageEnabled, &fit_to_paper_size)) {
|
||||
@@ -440,7 +437,6 @@ blink::WebPrintScalingOption GetPrintScalingOption(
|
||||
@@ -441,7 +438,6 @@ blink::WebPrintScalingOption GetPrintScalingOption(
|
||||
}
|
||||
return blink::kWebPrintScalingOptionFitToPrintableArea;
|
||||
}
|
||||
@@ -234,7 +277,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
|
||||
// Helper function to scale and round an integer value with a double valued
|
||||
// scaling.
|
||||
@@ -959,6 +955,7 @@ PrintRenderFrameHelper::PrintRenderFrameHelper(
|
||||
@@ -948,6 +944,7 @@ PrintRenderFrameHelper::PrintRenderFrameHelper(
|
||||
print_for_preview_(false),
|
||||
delegate_(std::move(delegate)),
|
||||
print_node_in_progress_(false),
|
||||
@@ -242,7 +285,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
is_loading_(false),
|
||||
is_scripted_preview_delayed_(false),
|
||||
ipc_nesting_level_(0),
|
||||
@@ -1020,10 +1017,8 @@ void PrintRenderFrameHelper::ScriptedPrint(bool user_initiated) {
|
||||
@@ -1009,10 +1006,8 @@ void PrintRenderFrameHelper::ScriptedPrint(bool user_initiated) {
|
||||
return;
|
||||
|
||||
if (g_is_preview_enabled) {
|
||||
@@ -253,7 +296,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
} else {
|
||||
#if BUILDFLAG(ENABLE_BASIC_PRINTING)
|
||||
auto weak_this = weak_ptr_factory_.GetWeakPtr();
|
||||
@@ -1055,13 +1050,11 @@ bool PrintRenderFrameHelper::OnMessageReceived(const IPC::Message& message) {
|
||||
@@ -1044,13 +1039,11 @@ bool PrintRenderFrameHelper::OnMessageReceived(const IPC::Message& message) {
|
||||
IPC_MESSAGE_HANDLER(PrintMsg_PrintPages, OnPrintPages)
|
||||
IPC_MESSAGE_HANDLER(PrintMsg_PrintForSystemDialog, OnPrintForSystemDialog)
|
||||
#endif // BUILDFLAG(ENABLE_BASIC_PRINTING)
|
||||
@@ -268,7 +311,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
IPC_MESSAGE_HANDLER(PrintMsg_ClosePrintPreviewDialog,
|
||||
OnClosePrintPreviewDialog)
|
||||
#endif // BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
@@ -1121,7 +1114,6 @@ void PrintRenderFrameHelper::OnPrintForSystemDialog() {
|
||||
@@ -1110,7 +1103,6 @@ void PrintRenderFrameHelper::OnPrintForSystemDialog() {
|
||||
}
|
||||
#endif // BUILDFLAG(ENABLE_BASIC_PRINTING)
|
||||
|
||||
@@ -276,7 +319,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
void PrintRenderFrameHelper::OnPrintForPrintPreview(
|
||||
const base::DictionaryValue& job_settings) {
|
||||
CHECK_LE(ipc_nesting_level_, 1);
|
||||
@@ -1181,7 +1173,6 @@ void PrintRenderFrameHelper::OnPrintForPrintPreview(
|
||||
@@ -1170,7 +1162,6 @@ void PrintRenderFrameHelper::OnPrintForPrintPreview(
|
||||
DidFinishPrinting(FAIL_PRINT);
|
||||
}
|
||||
}
|
||||
@@ -284,7 +327,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
|
||||
void PrintRenderFrameHelper::GetPageSizeAndContentAreaFromPageLayout(
|
||||
const PageSizeMargins& page_layout_in_points,
|
||||
@@ -1206,7 +1197,6 @@ void PrintRenderFrameHelper::UpdateFrameMarginsCssInfo(
|
||||
@@ -1195,7 +1186,6 @@ void PrintRenderFrameHelper::UpdateFrameMarginsCssInfo(
|
||||
ignore_css_margins_ = (margins_type != DEFAULT_MARGINS);
|
||||
}
|
||||
|
||||
@@ -292,7 +335,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
void PrintRenderFrameHelper::OnPrintPreview(
|
||||
const base::DictionaryValue& settings) {
|
||||
if (ipc_nesting_level_ > 1)
|
||||
@@ -1398,7 +1388,7 @@ bool PrintRenderFrameHelper::CreatePreviewDocument() {
|
||||
@@ -1387,7 +1377,7 @@ bool PrintRenderFrameHelper::CreatePreviewDocument() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -301,7 +344,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
bool PrintRenderFrameHelper::RenderPreviewPage(
|
||||
int page_number,
|
||||
const PrintMsg_Print_Params& print_params) {
|
||||
@@ -1428,7 +1418,7 @@ bool PrintRenderFrameHelper::RenderPreviewPage(
|
||||
@@ -1417,7 +1407,7 @@ bool PrintRenderFrameHelper::RenderPreviewPage(
|
||||
}
|
||||
return PreviewPageRendered(page_number, draft_metafile.get());
|
||||
}
|
||||
@@ -310,7 +353,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
|
||||
bool PrintRenderFrameHelper::FinalizePrintReadyDocument() {
|
||||
DCHECK(!is_print_ready_metafile_sent_);
|
||||
@@ -1457,7 +1447,6 @@ bool PrintRenderFrameHelper::FinalizePrintReadyDocument() {
|
||||
@@ -1446,7 +1436,6 @@ bool PrintRenderFrameHelper::FinalizePrintReadyDocument() {
|
||||
Send(new PrintHostMsg_MetafileReadyForPrinting(routing_id(), preview_params));
|
||||
return true;
|
||||
}
|
||||
@@ -318,7 +361,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
|
||||
void PrintRenderFrameHelper::OnPrintingDone(bool success) {
|
||||
if (ipc_nesting_level_ > 1)
|
||||
@@ -1472,7 +1461,6 @@ void PrintRenderFrameHelper::OnSetPrintingEnabled(bool enabled) {
|
||||
@@ -1461,7 +1450,6 @@ void PrintRenderFrameHelper::OnSetPrintingEnabled(bool enabled) {
|
||||
is_printing_enabled_ = enabled;
|
||||
}
|
||||
|
||||
@@ -326,7 +369,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
void PrintRenderFrameHelper::OnInitiatePrintPreview(bool has_selection) {
|
||||
if (ipc_nesting_level_ > 1)
|
||||
return;
|
||||
@@ -1483,7 +1471,9 @@ void PrintRenderFrameHelper::OnInitiatePrintPreview(bool has_selection) {
|
||||
@@ -1472,7 +1460,9 @@ void PrintRenderFrameHelper::OnInitiatePrintPreview(bool has_selection) {
|
||||
// that instead.
|
||||
auto plugin = delegate_->GetPdfElement(frame);
|
||||
if (!plugin.IsNull()) {
|
||||
@@ -336,7 +379,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
return;
|
||||
}
|
||||
print_preview_context_.InitWithFrame(frame);
|
||||
@@ -1492,10 +1482,11 @@ void PrintRenderFrameHelper::OnInitiatePrintPreview(bool has_selection) {
|
||||
@@ -1481,10 +1471,11 @@ void PrintRenderFrameHelper::OnInitiatePrintPreview(bool has_selection) {
|
||||
: PRINT_PREVIEW_USER_INITIATED_ENTIRE_FRAME);
|
||||
}
|
||||
|
||||
@@ -349,7 +392,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
|
||||
bool PrintRenderFrameHelper::IsPrintingEnabled() const {
|
||||
return is_printing_enabled_;
|
||||
@@ -1517,11 +1508,9 @@ void PrintRenderFrameHelper::PrintNode(const blink::WebNode& node) {
|
||||
@@ -1506,11 +1497,9 @@ void PrintRenderFrameHelper::PrintNode(const blink::WebNode& node) {
|
||||
|
||||
print_node_in_progress_ = true;
|
||||
|
||||
@@ -362,7 +405,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
} else {
|
||||
#if BUILDFLAG(ENABLE_BASIC_PRINTING)
|
||||
// Make a copy of the node, in case RenderView::OnContextMenuClosed() resets
|
||||
@@ -1611,7 +1600,6 @@ void PrintRenderFrameHelper::DidFinishPrinting(PrintingResult result) {
|
||||
@@ -1600,7 +1589,6 @@ void PrintRenderFrameHelper::DidFinishPrinting(PrintingResult result) {
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -370,7 +413,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
case FAIL_PREVIEW:
|
||||
if (!is_print_ready_metafile_sent_) {
|
||||
if (notify_browser_of_print_failure_) {
|
||||
@@ -1628,7 +1616,6 @@ void PrintRenderFrameHelper::DidFinishPrinting(PrintingResult result) {
|
||||
@@ -1617,7 +1605,6 @@ void PrintRenderFrameHelper::DidFinishPrinting(PrintingResult result) {
|
||||
cookie));
|
||||
print_preview_context_.Failed(false);
|
||||
break;
|
||||
@@ -378,7 +421,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
}
|
||||
prep_frame_view_.reset();
|
||||
print_pages_params_.reset();
|
||||
@@ -1757,7 +1744,6 @@ bool PrintRenderFrameHelper::CalculateNumberOfPages(blink::WebLocalFrame* frame,
|
||||
@@ -1798,7 +1785,6 @@ bool PrintRenderFrameHelper::CalculateNumberOfPages(blink::WebLocalFrame* frame,
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -386,7 +429,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
bool PrintRenderFrameHelper::SetOptionsFromPdfDocument(
|
||||
PrintHostMsg_SetOptionsFromDocument_Params* options) {
|
||||
blink::WebLocalFrame* source_frame = print_preview_context_.source_frame();
|
||||
@@ -1864,7 +1850,6 @@ bool PrintRenderFrameHelper::UpdatePrintSettings(
|
||||
@@ -1905,7 +1891,6 @@ bool PrintRenderFrameHelper::UpdatePrintSettings(
|
||||
print_preview_context_.set_error(PREVIEW_ERROR_INVALID_PRINTER_SETTINGS);
|
||||
return false;
|
||||
}
|
||||
@@ -394,7 +437,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
|
||||
#if BUILDFLAG(ENABLE_BASIC_PRINTING)
|
||||
void PrintRenderFrameHelper::GetPrintSettingsFromUser(
|
||||
@@ -2023,7 +2008,6 @@ bool PrintRenderFrameHelper::CopyMetafileDataToSharedMem(
|
||||
@@ -2058,7 +2043,6 @@ bool PrintRenderFrameHelper::CopyMetafileDataToSharedMem(
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -402,7 +445,7 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
void PrintRenderFrameHelper::ShowScriptedPrintPreview() {
|
||||
if (is_scripted_preview_delayed_) {
|
||||
is_scripted_preview_delayed_ = false;
|
||||
@@ -2158,7 +2142,6 @@ bool PrintRenderFrameHelper::PreviewPageRendered(int page_number,
|
||||
@@ -2193,7 +2177,6 @@ bool PrintRenderFrameHelper::PreviewPageRendered(int page_number,
|
||||
Send(new PrintHostMsg_DidPreviewPage(routing_id(), preview_page_params));
|
||||
return true;
|
||||
}
|
||||
@@ -411,10 +454,10 @@ index c6b03ed6ad9a..5f6545a3dee7 100644
|
||||
PrintRenderFrameHelper::PrintPreviewContext::PrintPreviewContext()
|
||||
: total_page_count_(0),
|
||||
diff --git components/printing/renderer/print_render_frame_helper.h components/printing/renderer/print_render_frame_helper.h
|
||||
index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
index cd174ca65085..bbef96f246ef 100644
|
||||
--- components/printing/renderer/print_render_frame_helper.h
|
||||
+++ components/printing/renderer/print_render_frame_helper.h
|
||||
@@ -156,10 +156,8 @@ class PrintRenderFrameHelper
|
||||
@@ -147,10 +147,8 @@ class PrintRenderFrameHelper
|
||||
OK,
|
||||
FAIL_PRINT_INIT,
|
||||
FAIL_PRINT,
|
||||
@@ -425,7 +468,7 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
};
|
||||
|
||||
enum PrintPreviewErrorBuckets {
|
||||
@@ -196,9 +194,9 @@ class PrintRenderFrameHelper
|
||||
@@ -187,9 +185,9 @@ class PrintRenderFrameHelper
|
||||
void OnPrintForSystemDialog();
|
||||
void OnPrintForPrintPreview(const base::DictionaryValue& job_settings);
|
||||
#endif // BUILDFLAG(ENABLE_BASIC_PRINTING)
|
||||
@@ -436,7 +479,7 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
void OnClosePrintPreviewDialog();
|
||||
#endif // BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
void OnPrintingDone(bool success);
|
||||
@@ -213,7 +211,6 @@ class PrintRenderFrameHelper
|
||||
@@ -204,7 +202,6 @@ class PrintRenderFrameHelper
|
||||
// Update |ignore_css_margins_| based on settings.
|
||||
void UpdateFrameMarginsCssInfo(const base::DictionaryValue& settings);
|
||||
|
||||
@@ -444,7 +487,7 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
// Prepare frame for creating preview document.
|
||||
void PrepareFrameForPreviewDocument();
|
||||
|
||||
@@ -230,7 +227,6 @@ class PrintRenderFrameHelper
|
||||
@@ -221,7 +218,6 @@ class PrintRenderFrameHelper
|
||||
|
||||
// Finalize the print ready preview document.
|
||||
bool FinalizePrintReadyDocument();
|
||||
@@ -452,7 +495,7 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
|
||||
// Enable/Disable printing.
|
||||
void OnSetPrintingEnabled(bool enabled);
|
||||
@@ -260,7 +256,6 @@ class PrintRenderFrameHelper
|
||||
@@ -251,7 +247,6 @@ class PrintRenderFrameHelper
|
||||
const blink::WebNode& node,
|
||||
int* number_of_pages);
|
||||
|
||||
@@ -460,7 +503,7 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
// Set options for print preset from source PDF document.
|
||||
bool SetOptionsFromPdfDocument(
|
||||
PrintHostMsg_SetOptionsFromDocument_Params* options);
|
||||
@@ -271,7 +266,6 @@ class PrintRenderFrameHelper
|
||||
@@ -262,7 +257,6 @@ class PrintRenderFrameHelper
|
||||
bool UpdatePrintSettings(blink::WebLocalFrame* frame,
|
||||
const blink::WebNode& node,
|
||||
const base::DictionaryValue& passed_job_settings);
|
||||
@@ -468,7 +511,7 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
|
||||
#if BUILDFLAG(ENABLE_BASIC_PRINTING)
|
||||
// Get final print settings from the user.
|
||||
@@ -375,7 +369,6 @@ class PrintRenderFrameHelper
|
||||
@@ -347,7 +341,6 @@ class PrintRenderFrameHelper
|
||||
bool IsScriptInitiatedPrintAllowed(blink::WebLocalFrame* frame,
|
||||
bool user_initiated);
|
||||
|
||||
@@ -476,7 +519,7 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
// Shows scripted print preview when options from plugin are available.
|
||||
void ShowScriptedPrintPreview();
|
||||
|
||||
@@ -393,7 +386,6 @@ class PrintRenderFrameHelper
|
||||
@@ -365,7 +358,6 @@ class PrintRenderFrameHelper
|
||||
// |metafile| is the rendered page. Otherwise |metafile| is NULL.
|
||||
// Returns true if print preview should continue, false on failure.
|
||||
bool PreviewPageRendered(int page_number, PdfMetafileSkia* metafile);
|
||||
@@ -484,7 +527,7 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
|
||||
void SetPrintPagesParams(const PrintMsg_PrintPages_Params& settings);
|
||||
|
||||
@@ -554,6 +546,7 @@ class PrintRenderFrameHelper
|
||||
@@ -526,6 +518,7 @@ class PrintRenderFrameHelper
|
||||
ScriptingThrottler scripting_throttler_;
|
||||
|
||||
bool print_node_in_progress_;
|
||||
@@ -493,22 +536,22 @@ index a9fe8cb7dcaf..ea35ea3cc920 100644
|
||||
bool is_loading_;
|
||||
bool is_scripted_preview_delayed_;
|
||||
diff --git components/printing/renderer/print_render_frame_helper_mac.mm components/printing/renderer/print_render_frame_helper_mac.mm
|
||||
index 42149955ee2c..ca6cb42ffce1 100644
|
||||
index 8cc4806de501..ba3d0dc6e621 100644
|
||||
--- components/printing/renderer/print_render_frame_helper_mac.mm
|
||||
+++ components/printing/renderer/print_render_frame_helper_mac.mm
|
||||
@@ -76,7 +76,6 @@ void PrintRenderFrameHelper::PrintPagesInternal(
|
||||
}
|
||||
}
|
||||
@@ -18,7 +18,6 @@
|
||||
|
||||
namespace printing {
|
||||
|
||||
-#if BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
bool PrintRenderFrameHelper::RenderPreviewPage(
|
||||
int page_number,
|
||||
const PrintMsg_Print_Params& print_params) {
|
||||
@@ -115,7 +114,6 @@ bool PrintRenderFrameHelper::RenderPreviewPage(
|
||||
@@ -56,7 +55,6 @@ bool PrintRenderFrameHelper::RenderPreviewPage(
|
||||
}
|
||||
return PreviewPageRendered(page_number, draft_metafile.get());
|
||||
}
|
||||
-#endif // BUILDFLAG(ENABLE_PRINT_PREVIEW)
|
||||
|
||||
void PrintRenderFrameHelper::RenderPage(const PrintMsg_Print_Params& params,
|
||||
int page_number,
|
||||
void PrintRenderFrameHelper::PrintPageInternal(
|
||||
const PrintMsg_Print_Params& params,
|
||||
|
@@ -1,17 +1,17 @@
|
||||
diff --git chrome/browser/printing/print_job_worker.cc chrome/browser/printing/print_job_worker.cc
|
||||
index 13434ba2f6cd..9e6734501057 100644
|
||||
index 6f185aef2feb..1c2e0fae7f47 100644
|
||||
--- chrome/browser/printing/print_job_worker.cc
|
||||
+++ chrome/browser/printing/print_job_worker.cc
|
||||
@@ -125,6 +125,7 @@ PrintJobWorker::PrintJobWorker(int render_process_id,
|
||||
printing_context_delegate_ = base::MakeUnique<PrintingContextDelegate>(
|
||||
render_process_id, render_frame_id);
|
||||
printing_context_ = PrintingContext::Create(printing_context_delegate_.get());
|
||||
@@ -129,6 +129,7 @@ PrintJobWorker::PrintJobWorker(int render_process_id,
|
||||
weak_factory_(this) {
|
||||
// The object is created in the IO thread.
|
||||
DCHECK(owner_->RunsTasksInCurrentSequence());
|
||||
+ printing_context_->set_render_ids(render_process_id, render_frame_id);
|
||||
}
|
||||
|
||||
PrintJobWorker::~PrintJobWorker() {
|
||||
diff --git printing/printing_context.h printing/printing_context.h
|
||||
index 03f940ca4684..d23a4a354d57 100644
|
||||
index 96934fb0d0c8..39d0019a9826 100644
|
||||
--- printing/printing_context.h
|
||||
+++ printing/printing_context.h
|
||||
@@ -127,6 +127,13 @@ class PRINTING_EXPORT PrintingContext {
|
||||
|
@@ -1,14 +0,0 @@
|
||||
diff --git ui/latency/latency_histogram_macros.h ui/latency/latency_histogram_macros.h
|
||||
index 77e3eeef70ba..f8dd6350c120 100644
|
||||
--- ui/latency/latency_histogram_macros.h
|
||||
+++ ui/latency/latency_histogram_macros.h
|
||||
@@ -10,8 +10,7 @@
|
||||
// Check valid timing for start and end latency components.
|
||||
#define CONFIRM_VALID_TIMING(start, end) \
|
||||
DCHECK(!start.first_event_time.is_null()); \
|
||||
- DCHECK(!end.last_event_time.is_null()); \
|
||||
- DCHECK_GE(end.last_event_time, start.first_event_time);
|
||||
+ DCHECK(!end.last_event_time.is_null());
|
||||
|
||||
// Event latency that is mostly under 1 second. We should only use 100 buckets
|
||||
// when needed.
|
@@ -1,5 +1,5 @@
|
||||
diff --git chrome/browser/renderer_preferences_util.cc chrome/browser/renderer_preferences_util.cc
|
||||
index 7296a04a56cc..c702d3178eb6 100644
|
||||
index ef8350dd1f99..601db5845c8a 100644
|
||||
--- chrome/browser/renderer_preferences_util.cc
|
||||
+++ chrome/browser/renderer_preferences_util.cc
|
||||
@@ -32,7 +32,8 @@
|
||||
@@ -12,8 +12,8 @@ index 7296a04a56cc..c702d3178eb6 100644
|
||||
#include "chrome/browser/themes/theme_service.h"
|
||||
#include "chrome/browser/themes/theme_service_factory.h"
|
||||
#include "ui/views/linux_ui/linux_ui.h"
|
||||
@@ -134,7 +135,8 @@ void UpdateFromSystemSettings(content::RendererPreferences* prefs,
|
||||
prefs->caret_blink_interval = interval.InSecondsF();
|
||||
@@ -136,7 +137,8 @@ void UpdateFromSystemSettings(content::RendererPreferences* prefs,
|
||||
prefs->caret_blink_interval = interval;
|
||||
#endif
|
||||
|
||||
-#if defined(USE_AURA) && defined(OS_LINUX) && !defined(OS_CHROMEOS)
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git content/browser/renderer_host/render_widget_host_view_aura.cc content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
index 7f727c290067..9d8a4683411f 100644
|
||||
index 3adf96eda163..673f4c689fcb 100644
|
||||
--- content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -426,13 +426,6 @@ RenderWidgetHostViewAura::RenderWidgetHostViewAura(
|
||||
@@ -435,13 +435,6 @@ RenderWidgetHostViewAura::RenderWidgetHostViewAura(
|
||||
selection_controller_client_.reset(
|
||||
new TouchSelectionControllerClientAura(this));
|
||||
CreateSelectionController();
|
||||
@@ -16,7 +16,7 @@ index 7f727c290067..9d8a4683411f 100644
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
@@ -750,8 +743,10 @@ void RenderWidgetHostViewAura::UpdateBackgroundColorFromRenderer(
|
||||
@@ -775,8 +768,10 @@ void RenderWidgetHostViewAura::UpdateBackgroundColorFromRenderer(
|
||||
background_color_ = color;
|
||||
|
||||
bool opaque = SkColorGetA(color) == SK_AlphaOPAQUE;
|
||||
@@ -29,7 +29,7 @@ index 7f727c290067..9d8a4683411f 100644
|
||||
}
|
||||
|
||||
bool RenderWidgetHostViewAura::IsMouseLocked() {
|
||||
@@ -1913,6 +1908,15 @@ void RenderWidgetHostViewAura::CreateAuraWindow(aura::client::WindowType type) {
|
||||
@@ -1961,6 +1956,15 @@ void RenderWidgetHostViewAura::CreateAuraWindow(aura::client::WindowType type) {
|
||||
window_->Init(ui::LAYER_SOLID_COLOR);
|
||||
window_->layer()->SetColor(background_color_);
|
||||
|
||||
@@ -42,6 +42,6 @@ index 7f727c290067..9d8a4683411f 100644
|
||||
+ ignore_result(rvh->GetWebkitPreferences());
|
||||
+ }
|
||||
+
|
||||
if (!IsMus())
|
||||
if (!IsUsingMus())
|
||||
return;
|
||||
|
||||
|
@@ -1,9 +1,9 @@
|
||||
diff --git chrome/browser/spellchecker/spellcheck_factory.cc chrome/browser/spellchecker/spellcheck_factory.cc
|
||||
index 9f9eb3bdd044..63988fba828d 100644
|
||||
index 148ec2086d1f..cc7f9ac83481 100644
|
||||
--- chrome/browser/spellchecker/spellcheck_factory.cc
|
||||
+++ chrome/browser/spellchecker/spellcheck_factory.cc
|
||||
@@ -17,6 +17,13 @@
|
||||
#include "content/public/browser/render_process_host.h"
|
||||
@@ -18,6 +18,13 @@
|
||||
#include "services/service_manager/public/cpp/identity.h"
|
||||
#include "ui/base/l10n/l10n_util.h"
|
||||
|
||||
+namespace {
|
||||
@@ -16,7 +16,7 @@ index 9f9eb3bdd044..63988fba828d 100644
|
||||
// static
|
||||
SpellcheckService* SpellcheckServiceFactory::GetForContext(
|
||||
content::BrowserContext* context) {
|
||||
@@ -39,7 +46,7 @@ SpellcheckService* SpellcheckServiceFactory::GetForRenderProcessId(
|
||||
@@ -38,7 +45,7 @@ SpellcheckService* SpellcheckServiceFactory::GetForRenderer(
|
||||
|
||||
// static
|
||||
SpellcheckServiceFactory* SpellcheckServiceFactory::GetInstance() {
|
||||
@@ -26,7 +26,7 @@ index 9f9eb3bdd044..63988fba828d 100644
|
||||
|
||||
SpellcheckServiceFactory::SpellcheckServiceFactory()
|
||||
diff --git chrome/browser/spellchecker/spellcheck_factory.h chrome/browser/spellchecker/spellcheck_factory.h
|
||||
index e8eb9f7e8aa6..2e1b7cf84081 100644
|
||||
index fd4e6643725c..fcdbb8e4db88 100644
|
||||
--- chrome/browser/spellchecker/spellcheck_factory.h
|
||||
+++ chrome/browser/spellchecker/spellcheck_factory.h
|
||||
@@ -7,7 +7,7 @@
|
||||
@@ -38,7 +38,7 @@ index e8eb9f7e8aa6..2e1b7cf84081 100644
|
||||
#include "components/keyed_service/content/browser_context_keyed_service_factory.h"
|
||||
|
||||
class SpellcheckService;
|
||||
@@ -26,7 +26,7 @@ class SpellcheckServiceFactory : public BrowserContextKeyedServiceFactory {
|
||||
@@ -31,7 +31,7 @@ class SpellcheckServiceFactory : public BrowserContextKeyedServiceFactory {
|
||||
static SpellcheckServiceFactory* GetInstance();
|
||||
|
||||
private:
|
||||
@@ -97,7 +97,7 @@ index 2907619549ba..f941fba363b5 100644
|
||||
|
||||
SupervisedUserSettingsServiceFactory();
|
||||
diff --git chrome/browser/ui/prefs/prefs_tab_helper.cc chrome/browser/ui/prefs/prefs_tab_helper.cc
|
||||
index 149dbc568f54..ec01bd851d9c 100644
|
||||
index 23dfe243fb83..7eb879cadcbb 100644
|
||||
--- chrome/browser/ui/prefs/prefs_tab_helper.cc
|
||||
+++ chrome/browser/ui/prefs/prefs_tab_helper.cc
|
||||
@@ -11,8 +11,8 @@
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git services/service_manager/embedder/main.cc services/service_manager/embedder/main.cc
|
||||
index 87ac6f053947..868ff9e0c115 100644
|
||||
index 08ea94a11772..873726c6ea19 100644
|
||||
--- services/service_manager/embedder/main.cc
|
||||
+++ services/service_manager/embedder/main.cc
|
||||
@@ -317,13 +317,30 @@ int RunService(MainDelegate* delegate) {
|
||||
@@ -304,13 +304,30 @@ int RunService(MainDelegate* delegate) {
|
||||
return exit_code;
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ index 87ac6f053947..868ff9e0c115 100644
|
||||
MainDelegate* delegate = params.delegate;
|
||||
DCHECK(delegate);
|
||||
|
||||
@@ -391,30 +408,14 @@ int Main(const MainParams& params) {
|
||||
@@ -378,30 +395,14 @@ int Main(const MainParams& params) {
|
||||
MainDelegate::InitializeParams init_params;
|
||||
|
||||
#if defined(OS_MACOSX)
|
||||
@@ -43,7 +43,7 @@ index 87ac6f053947..868ff9e0c115 100644
|
||||
- // Each "main" needs to flush this pool right before it goes into its main
|
||||
- // event loop to get rid of the cruft.
|
||||
- std::unique_ptr<base::mac::ScopedNSAutoreleasePool> autorelease_pool =
|
||||
- base::MakeUnique<base::mac::ScopedNSAutoreleasePool>();
|
||||
- std::make_unique<base::mac::ScopedNSAutoreleasePool>();
|
||||
- init_params.autorelease_pool = autorelease_pool.get();
|
||||
+ init_params.autorelease_pool = params.autorelease_pool.get();
|
||||
InitializeMac();
|
||||
@@ -69,7 +69,7 @@ index 87ac6f053947..868ff9e0c115 100644
|
||||
mojo_config.max_message_num_bytes = kMaximumMojoMessageSize;
|
||||
delegate->OverrideMojoConfiguration(&mojo_config);
|
||||
mojo::edk::Init(mojo_config);
|
||||
@@ -449,6 +450,16 @@ int Main(const MainParams& params) {
|
||||
@@ -436,6 +437,16 @@ int Main(const MainParams& params) {
|
||||
trace_config, base::trace_event::TraceLog::RECORDING_MODE);
|
||||
}
|
||||
|
||||
@@ -86,7 +86,7 @@ index 87ac6f053947..868ff9e0c115 100644
|
||||
switch (process_type) {
|
||||
case ProcessType::kDefault:
|
||||
NOTREACHED();
|
||||
@@ -470,6 +481,8 @@ int Main(const MainParams& params) {
|
||||
@@ -457,6 +468,8 @@ int Main(const MainParams& params) {
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -95,7 +95,7 @@ index 87ac6f053947..868ff9e0c115 100644
|
||||
if (tracker) {
|
||||
if (exit_code == 0) {
|
||||
tracker->SetProcessPhaseIfEnabled(
|
||||
@@ -481,13 +494,38 @@ int Main(const MainParams& params) {
|
||||
@@ -468,13 +481,38 @@ int Main(const MainParams& params) {
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -14,10 +14,10 @@ index 71bf90c54ae5..d3308da307d7 100644
|
||||
}
|
||||
|
||||
diff --git content/browser/blob_storage/chrome_blob_storage_context.cc content/browser/blob_storage/chrome_blob_storage_context.cc
|
||||
index 325736ab142b..cbb25b803aa6 100644
|
||||
index bf41a25bcd29..9e6dd89497e7 100644
|
||||
--- content/browser/blob_storage/chrome_blob_storage_context.cc
|
||||
+++ content/browser/blob_storage/chrome_blob_storage_context.cc
|
||||
@@ -78,6 +78,11 @@ class BlobHandleImpl : public BlobHandle {
|
||||
@@ -76,6 +76,11 @@ class BlobHandleImpl : public BlobHandle {
|
||||
|
||||
ChromeBlobStorageContext::ChromeBlobStorageContext() {}
|
||||
|
||||
@@ -30,7 +30,7 @@ index 325736ab142b..cbb25b803aa6 100644
|
||||
BrowserContext* context) {
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
diff --git content/browser/blob_storage/chrome_blob_storage_context.h content/browser/blob_storage/chrome_blob_storage_context.h
|
||||
index 00b61232c391..aa915f3130d1 100644
|
||||
index 2412f15c5fb7..3434d129af64 100644
|
||||
--- content/browser/blob_storage/chrome_blob_storage_context.h
|
||||
+++ content/browser/blob_storage/chrome_blob_storage_context.h
|
||||
@@ -47,6 +47,8 @@ class CONTENT_EXPORT ChromeBlobStorageContext
|
||||
@@ -43,7 +43,7 @@ index 00b61232c391..aa915f3130d1 100644
|
||||
static ChromeBlobStorageContext* GetFor(
|
||||
BrowserContext* browser_context);
|
||||
diff --git content/browser/bluetooth/web_bluetooth_service_impl.cc content/browser/bluetooth/web_bluetooth_service_impl.cc
|
||||
index 13d802fa72cd..a2d34d1d72eb 100644
|
||||
index e5c7291dcc8f..0eec8a11db35 100644
|
||||
--- content/browser/bluetooth/web_bluetooth_service_impl.cc
|
||||
+++ content/browser/bluetooth/web_bluetooth_service_impl.cc
|
||||
@@ -1233,9 +1233,9 @@ url::Origin WebBluetoothServiceImpl::GetOrigin() {
|
||||
@@ -59,10 +59,10 @@ index 13d802fa72cd..a2d34d1d72eb 100644
|
||||
partition->GetBluetoothAllowedDevicesMap();
|
||||
return allowed_devices_map->GetOrCreateAllowedDevices(GetOrigin());
|
||||
diff --git content/browser/browser_context.cc content/browser/browser_context.cc
|
||||
index 1e3eb64f87ba..593e3d15d5ec 100644
|
||||
index 125078b9cb44..b24609a807ba 100644
|
||||
--- content/browser/browser_context.cc
|
||||
+++ content/browser/browser_context.cc
|
||||
@@ -123,11 +123,18 @@ StoragePartition* GetStoragePartitionFromConfig(
|
||||
@@ -127,11 +127,18 @@ StoragePartition* GetStoragePartitionFromConfig(
|
||||
StoragePartitionImplMap* partition_map =
|
||||
GetStoragePartitionMap(browser_context);
|
||||
|
||||
@@ -84,7 +84,7 @@ index 1e3eb64f87ba..593e3d15d5ec 100644
|
||||
}
|
||||
|
||||
void SaveSessionStateOnIOThread(
|
||||
@@ -548,6 +555,11 @@ ServiceManagerConnection* BrowserContext::GetServiceManagerConnectionFor(
|
||||
@@ -553,6 +560,11 @@ ServiceManagerConnection* BrowserContext::GetServiceManagerConnectionFor(
|
||||
BrowserContext::BrowserContext()
|
||||
: media_device_id_salt_(CreateRandomMediaDeviceIDSalt()) {}
|
||||
|
||||
@@ -97,10 +97,10 @@ index 1e3eb64f87ba..593e3d15d5ec 100644
|
||||
CHECK(GetUserData(kMojoWasInitialized))
|
||||
<< "Attempting to destroy a BrowserContext that never called "
|
||||
diff --git content/browser/devtools/protocol/service_worker_handler.cc content/browser/devtools/protocol/service_worker_handler.cc
|
||||
index a65884075126..241653eb4fd6 100644
|
||||
index d2478ae31473..5fd30c1cd72c 100644
|
||||
--- content/browser/devtools/protocol/service_worker_handler.cc
|
||||
+++ content/browser/devtools/protocol/service_worker_handler.cc
|
||||
@@ -334,8 +334,7 @@ Response ServiceWorkerHandler::DispatchSyncEvent(
|
||||
@@ -337,8 +337,7 @@ Response ServiceWorkerHandler::DispatchSyncEvent(
|
||||
if (!base::StringToInt64(registration_id, &id))
|
||||
return CreateInvalidVersionIdErrorResponse();
|
||||
|
||||
@@ -111,12 +111,12 @@ index a65884075126..241653eb4fd6 100644
|
||||
|
||||
BrowserThread::PostTask(BrowserThread::IO, FROM_HERE,
|
||||
diff --git content/browser/download/download_manager_impl.cc content/browser/download/download_manager_impl.cc
|
||||
index 68293acdadc6..ca613c9218c8 100644
|
||||
index 0992aad5fe6c..788d432c48d9 100644
|
||||
--- content/browser/download/download_manager_impl.cc
|
||||
+++ content/browser/download/download_manager_impl.cc
|
||||
@@ -69,9 +69,9 @@
|
||||
namespace content {
|
||||
namespace {
|
||||
@@ -83,9 +83,9 @@ WebContents* GetWebContents(int render_process_id,
|
||||
return WebContents::FromFrameTreeNodeId(frame_tree_node_id);
|
||||
}
|
||||
|
||||
-StoragePartitionImpl* GetStoragePartition(BrowserContext* context,
|
||||
- int render_process_id,
|
||||
@@ -127,7 +127,7 @@ index 68293acdadc6..ca613c9218c8 100644
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
|
||||
SiteInstance* site_instance = nullptr;
|
||||
@@ -81,8 +81,7 @@ StoragePartitionImpl* GetStoragePartition(BrowserContext* context,
|
||||
@@ -95,8 +95,7 @@ StoragePartitionImpl* GetStoragePartition(BrowserContext* context,
|
||||
if (render_frame_host_)
|
||||
site_instance = render_frame_host_->GetSiteInstance();
|
||||
}
|
||||
@@ -137,7 +137,7 @@ index 68293acdadc6..ca613c9218c8 100644
|
||||
}
|
||||
|
||||
bool CanRequestURLFromRenderer(int render_process_id, GURL url) {
|
||||
@@ -737,14 +736,15 @@ void DownloadManagerImpl::DownloadUrl(
|
||||
@@ -987,16 +986,17 @@ void DownloadManagerImpl::BeginDownloadInternal(
|
||||
if (base::FeatureList::IsEnabled(features::kNetworkService)) {
|
||||
std::unique_ptr<ResourceRequest> request = CreateResourceRequest(
|
||||
params.get());
|
||||
@@ -150,31 +150,39 @@ index 68293acdadc6..ca613c9218c8 100644
|
||||
base::BindOnce(
|
||||
&BeginResourceDownload, std::move(params), std::move(request),
|
||||
- storage_partition->url_loader_factory_getter(),
|
||||
- base::WrapRefCounted(storage_partition->GetFileSystemContext()),
|
||||
- id, weak_factory_.GetWeakPtr()),
|
||||
+ base::WrapRefCounted(
|
||||
+ storage_partition->url_loader_factory_getter()),
|
||||
base::WrapRefCounted(storage_partition->GetFileSystemContext()),
|
||||
content::DownloadItem::kInvalidId, weak_factory_.GetWeakPtr()),
|
||||
+ base::WrapRefCounted(storage_partition->GetFileSystemContext()),
|
||||
+ id, weak_factory_.GetWeakPtr()),
|
||||
base::BindOnce(&DownloadManagerImpl::AddUrlDownloadHandler,
|
||||
weak_factory_.GetWeakPtr()));
|
||||
} else {
|
||||
diff --git content/browser/loader/navigation_url_loader_network_service.cc content/browser/loader/navigation_url_loader_network_service.cc
|
||||
index dadbbdcc8fc8..1fd206309eb8 100644
|
||||
index 70148056059b..599b068dfdea 100644
|
||||
--- content/browser/loader/navigation_url_loader_network_service.cc
|
||||
+++ content/browser/loader/navigation_url_loader_network_service.cc
|
||||
@@ -579,8 +579,8 @@ NavigationURLLoaderNetworkService::NavigationURLLoaderNetworkService(
|
||||
@@ -615,11 +615,12 @@ NavigationURLLoaderNetworkService::NavigationURLLoaderNetworkService(
|
||||
|
||||
g_next_request_id--;
|
||||
|
||||
- auto* partition = static_cast<StoragePartitionImpl*>(storage_partition);
|
||||
+ auto* partition = storage_partition;
|
||||
DCHECK(!request_controller_);
|
||||
request_controller_ = base::MakeUnique<URLLoaderRequestController>(
|
||||
request_controller_ = std::make_unique<URLLoaderRequestController>(
|
||||
std::move(initial_handlers), std::move(new_request), resource_context,
|
||||
- static_cast<StoragePartitionImpl*>(storage_partition)
|
||||
- ->url_loader_factory_getter(),
|
||||
+ scoped_refptr<URLLoaderFactoryGetter>(
|
||||
+ storage_partition->url_loader_factory_getter()),
|
||||
weak_factory_.GetWeakPtr());
|
||||
- partition->url_loader_factory_getter(), weak_factory_.GetWeakPtr());
|
||||
+ base::WrapRefCounted(partition->url_loader_factory_getter()),
|
||||
+ weak_factory_.GetWeakPtr());
|
||||
BrowserThread::PostTask(
|
||||
BrowserThread::IO, FROM_HERE,
|
||||
base::BindOnce(&URLLoaderRequestController::Start,
|
||||
diff --git content/browser/payments/payment_app_provider_impl.cc content/browser/payments/payment_app_provider_impl.cc
|
||||
index 337411c80e5a..7acc48a745a2 100644
|
||||
index 8816724941ff..6b9a26b7c615 100644
|
||||
--- content/browser/payments/payment_app_provider_impl.cc
|
||||
+++ content/browser/payments/payment_app_provider_impl.cc
|
||||
@@ -328,10 +328,11 @@ void StartServiceWorkerForDispatch(BrowserContext* browser_context,
|
||||
@@ -329,10 +329,11 @@ void StartServiceWorkerForDispatch(BrowserContext* browser_context,
|
||||
ServiceWorkerStartCallback callback) {
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
|
||||
@@ -189,7 +197,7 @@ index 337411c80e5a..7acc48a745a2 100644
|
||||
|
||||
BrowserThread::PostTask(
|
||||
BrowserThread::IO, FROM_HERE,
|
||||
@@ -357,8 +358,8 @@ void PaymentAppProviderImpl::GetAllPaymentApps(
|
||||
@@ -358,8 +359,8 @@ void PaymentAppProviderImpl::GetAllPaymentApps(
|
||||
GetAllPaymentAppsCallback callback) {
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
|
||||
@@ -201,10 +209,10 @@ index 337411c80e5a..7acc48a745a2 100644
|
||||
partition->GetPaymentAppContext();
|
||||
|
||||
diff --git content/browser/renderer_host/render_process_host_impl.cc content/browser/renderer_host/render_process_host_impl.cc
|
||||
index 44207cf02ab6..a59cd89a31f8 100644
|
||||
index a61b8ab0886e..5be550085df1 100644
|
||||
--- content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -493,9 +493,8 @@ class SpareRenderProcessHostManager : public RenderProcessHostObserver {
|
||||
@@ -500,9 +500,8 @@ class SpareRenderProcessHostManager : public RenderProcessHostObserver {
|
||||
SpareRenderProcessHostManager() {}
|
||||
|
||||
void WarmupSpareRenderProcessHost(BrowserContext* browser_context) {
|
||||
@@ -216,7 +224,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
|
||||
if (spare_render_process_host_ &&
|
||||
matching_browser_context_ == browser_context &&
|
||||
@@ -634,11 +633,10 @@ class DefaultSubframeProcessHostHolder : public base::SupportsUserData::Data,
|
||||
@@ -641,11 +640,10 @@ class DefaultSubframeProcessHostHolder : public base::SupportsUserData::Data,
|
||||
// Gets the correct render process to use for this SiteInstance.
|
||||
RenderProcessHost* GetProcessHost(SiteInstance* site_instance,
|
||||
bool is_for_guests_only) {
|
||||
@@ -232,7 +240,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
|
||||
// Is this the default storage partition? If it isn't, then just give it its
|
||||
// own non-shared process.
|
||||
@@ -1206,7 +1204,7 @@ void RenderProcessHost::SetMaxRendererProcessCount(size_t count) {
|
||||
@@ -1240,7 +1238,7 @@ void RenderProcessHost::SetMaxRendererProcessCount(size_t count) {
|
||||
// static
|
||||
RenderProcessHost* RenderProcessHostImpl::CreateRenderProcessHost(
|
||||
BrowserContext* browser_context,
|
||||
@@ -241,7 +249,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
SiteInstance* site_instance,
|
||||
bool is_for_guests_only) {
|
||||
if (g_render_process_host_factory_) {
|
||||
@@ -1215,8 +1213,8 @@ RenderProcessHost* RenderProcessHostImpl::CreateRenderProcessHost(
|
||||
@@ -1249,8 +1247,8 @@ RenderProcessHost* RenderProcessHostImpl::CreateRenderProcessHost(
|
||||
}
|
||||
|
||||
if (!storage_partition_impl) {
|
||||
@@ -252,7 +260,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
}
|
||||
|
||||
return new RenderProcessHostImpl(browser_context, storage_partition_impl,
|
||||
@@ -1226,7 +1224,7 @@ RenderProcessHost* RenderProcessHostImpl::CreateRenderProcessHost(
|
||||
@@ -1260,7 +1258,7 @@ RenderProcessHost* RenderProcessHostImpl::CreateRenderProcessHost(
|
||||
// static
|
||||
RenderProcessHost* RenderProcessHostImpl::CreateOrUseSpareRenderProcessHost(
|
||||
BrowserContext* browser_context,
|
||||
@@ -261,7 +269,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
SiteInstance* site_instance,
|
||||
bool is_for_guests_only) {
|
||||
RenderProcessHost* render_process_host =
|
||||
@@ -1246,7 +1244,7 @@ RenderProcessHost* RenderProcessHostImpl::CreateOrUseSpareRenderProcessHost(
|
||||
@@ -1280,7 +1278,7 @@ RenderProcessHost* RenderProcessHostImpl::CreateOrUseSpareRenderProcessHost(
|
||||
|
||||
RenderProcessHostImpl::RenderProcessHostImpl(
|
||||
BrowserContext* browser_context,
|
||||
@@ -270,7 +278,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
bool is_for_guests_only)
|
||||
: fast_shutdown_started_(false),
|
||||
deleting_soon_(false),
|
||||
@@ -1282,7 +1280,8 @@ RenderProcessHostImpl::RenderProcessHostImpl(
|
||||
@@ -1316,7 +1314,8 @@ RenderProcessHostImpl::RenderProcessHostImpl(
|
||||
indexed_db_factory_(new IndexedDBDispatcherHost(
|
||||
id_,
|
||||
storage_partition_impl_->GetURLRequestContext(),
|
||||
@@ -280,7 +288,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
ChromeBlobStorageContext::GetFor(browser_context_))),
|
||||
channel_connected_(false),
|
||||
sent_render_process_ready_(false),
|
||||
@@ -1316,7 +1315,8 @@ RenderProcessHostImpl::RenderProcessHostImpl(
|
||||
@@ -1350,7 +1349,8 @@ RenderProcessHostImpl::RenderProcessHostImpl(
|
||||
}
|
||||
|
||||
push_messaging_manager_.reset(new PushMessagingManager(
|
||||
@@ -290,7 +298,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
|
||||
AddObserver(indexed_db_factory_.get());
|
||||
|
||||
@@ -1620,6 +1620,20 @@ void RenderProcessHostImpl::ResetChannelProxy() {
|
||||
@@ -1665,6 +1665,20 @@ void RenderProcessHostImpl::ResetChannelProxy() {
|
||||
|
||||
void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
@@ -311,7 +319,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
AddFilter(new ResourceSchedulerFilter(GetID()));
|
||||
MediaInternals* media_internals = MediaInternals::GetInstance();
|
||||
// Add BrowserPluginMessageFilter to ensure it gets the first stab at messages
|
||||
@@ -1634,8 +1648,8 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
@@ -1679,8 +1693,8 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
new RenderMessageFilter(
|
||||
GetID(), GetBrowserContext(), request_context.get(),
|
||||
widget_helper_.get(), media_internals,
|
||||
@@ -322,7 +330,7 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
AddFilter(render_message_filter.get());
|
||||
|
||||
render_frame_message_filter_ = new RenderFrameMessageFilter(
|
||||
@@ -1664,10 +1678,10 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
@@ -1709,10 +1723,10 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
ChromeBlobStorageContext::GetFor(browser_context);
|
||||
|
||||
resource_message_filter_ = new ResourceMessageFilter(
|
||||
@@ -335,20 +343,19 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
BrowserThread::GetTaskRunnerForThread(BrowserThread::IO));
|
||||
|
||||
AddFilter(resource_message_filter_.get());
|
||||
@@ -1694,10 +1708,10 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
@@ -1735,9 +1749,9 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
AddFilter(
|
||||
new MidiHost(GetID(), BrowserMainLoop::GetInstance()->midi_service()));
|
||||
AddFilter(new AppCacheDispatcherHost(
|
||||
- storage_partition_impl_->GetAppCacheService(), GetID()));
|
||||
+ app_cache_service, GetID()));
|
||||
AddFilter(new ClipboardMessageFilter(blob_storage_context));
|
||||
AddFilter(new DOMStorageMessageFilter(
|
||||
- storage_partition_impl_->GetDOMStorageContext()));
|
||||
+ dom_storage_context));
|
||||
|
||||
#if BUILDFLAG(ENABLE_WEBRTC)
|
||||
peer_connection_tracker_host_ = new PeerConnectionTrackerHost(
|
||||
@@ -1731,13 +1745,12 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
@@ -1765,13 +1779,12 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
|
||||
scoped_refptr<CacheStorageDispatcherHost> cache_storage_filter =
|
||||
new CacheStorageDispatcherHost();
|
||||
@@ -364,9 +371,9 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
AddFilter(service_worker_filter.get());
|
||||
|
||||
#if BUILDFLAG(ENABLE_WEBRTC)
|
||||
@@ -1752,11 +1765,8 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
GetID(), storage_partition_impl_->GetQuotaManager(),
|
||||
GetContentClient()->browser()->CreateQuotaPermissionContext()));
|
||||
@@ -1783,11 +1796,8 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
AddFilter(new TraceMessageFilter(GetID()));
|
||||
AddFilter(new ResolveProxyMsgHelper(request_context.get()));
|
||||
|
||||
- scoped_refptr<ServiceWorkerContextWrapper> service_worker_context(
|
||||
- static_cast<ServiceWorkerContextWrapper*>(
|
||||
@@ -377,41 +384,19 @@ index 44207cf02ab6..a59cd89a31f8 100644
|
||||
resource_context, service_worker_context, browser_context);
|
||||
AddFilter(notification_message_filter_.get());
|
||||
|
||||
@@ -1771,6 +1781,11 @@ void RenderProcessHostImpl::CreateMessageFilters() {
|
||||
void RenderProcessHostImpl::RegisterMojoInterfaces() {
|
||||
auto registry = base::MakeUnique<service_manager::BinderRegistry>();
|
||||
|
||||
+ // Cast to the derived type from StoragePartitionImpl.
|
||||
+ auto platform_notification_context =
|
||||
+ static_cast<PlatformNotificationContextImpl*>(
|
||||
+ storage_partition_impl_->GetPlatformNotificationContext());
|
||||
+
|
||||
channel_->AddAssociatedInterfaceForIOThread(
|
||||
base::Bind(&IndexedDBDispatcherHost::AddBinding,
|
||||
base::Unretained(indexed_db_factory_.get())));
|
||||
@@ -1825,8 +1840,7 @@ void RenderProcessHostImpl::RegisterMojoInterfaces() {
|
||||
AddUIThreadInterface(
|
||||
registry.get(),
|
||||
base::Bind(&PlatformNotificationContextImpl::CreateService,
|
||||
- base::Unretained(
|
||||
- storage_partition_impl_->GetPlatformNotificationContext()),
|
||||
+ base::Unretained(platform_notification_context),
|
||||
GetID()));
|
||||
AddUIThreadInterface(
|
||||
registry.get(),
|
||||
diff --git content/browser/renderer_host/render_process_host_impl.h content/browser/renderer_host/render_process_host_impl.h
|
||||
index dd7df59cb5c4..3c802e969d80 100644
|
||||
index b5528d49e678..aaecb9f0b0f7 100644
|
||||
--- content/browser/renderer_host/render_process_host_impl.h
|
||||
+++ content/browser/renderer_host/render_process_host_impl.h
|
||||
@@ -87,7 +87,6 @@ class ResourceMessageFilter;
|
||||
@@ -84,7 +84,6 @@ class ResourceMessageFilter;
|
||||
class SiteInstance;
|
||||
class SiteInstanceImpl;
|
||||
class StoragePartition;
|
||||
-class StoragePartitionImpl;
|
||||
|
||||
typedef base::Thread* (*RendererMainThreadFactoryFunction)(
|
||||
const InProcessChildThreadParams& params);
|
||||
@@ -126,7 +125,7 @@ class CONTENT_EXPORT RenderProcessHostImpl
|
||||
#if BUILDFLAG(ENABLE_WEBRTC)
|
||||
class MediaStreamDispatcherHost;
|
||||
@@ -128,7 +127,7 @@ class CONTENT_EXPORT RenderProcessHostImpl
|
||||
// legal).
|
||||
static RenderProcessHost* CreateOrUseSpareRenderProcessHost(
|
||||
BrowserContext* browser_context,
|
||||
@@ -420,7 +405,7 @@ index dd7df59cb5c4..3c802e969d80 100644
|
||||
SiteInstance* site_instance,
|
||||
bool is_for_guests_only);
|
||||
|
||||
@@ -138,7 +137,7 @@ class CONTENT_EXPORT RenderProcessHostImpl
|
||||
@@ -140,7 +139,7 @@ class CONTENT_EXPORT RenderProcessHostImpl
|
||||
// null.
|
||||
static RenderProcessHost* CreateRenderProcessHost(
|
||||
BrowserContext* browser_context,
|
||||
@@ -429,7 +414,7 @@ index dd7df59cb5c4..3c802e969d80 100644
|
||||
SiteInstance* site_instance,
|
||||
bool is_for_guests_only);
|
||||
|
||||
@@ -417,7 +416,7 @@ class CONTENT_EXPORT RenderProcessHostImpl
|
||||
@@ -422,7 +421,7 @@ class CONTENT_EXPORT RenderProcessHostImpl
|
||||
// Use CreateRenderProcessHost() instead of calling this constructor
|
||||
// directly.
|
||||
RenderProcessHostImpl(BrowserContext* browser_context,
|
||||
@@ -438,7 +423,7 @@ index dd7df59cb5c4..3c802e969d80 100644
|
||||
bool is_for_guests_only);
|
||||
|
||||
// Initializes a new IPC::ChannelProxy in |channel_|, which will be connected
|
||||
@@ -647,10 +646,10 @@ class CONTENT_EXPORT RenderProcessHostImpl
|
||||
@@ -657,10 +656,10 @@ class CONTENT_EXPORT RenderProcessHostImpl
|
||||
// called.
|
||||
int instance_id_ = 1;
|
||||
|
||||
@@ -451,15 +436,102 @@ index dd7df59cb5c4..3c802e969d80 100644
|
||||
|
||||
// The observers watching our lifetime.
|
||||
base::ObserverList<RenderProcessHostObserver> observers_;
|
||||
diff --git content/browser/renderer_interface_binders.cc content/browser/renderer_interface_binders.cc
|
||||
index 082e5c990dcc..8398a8613b08 100644
|
||||
--- content/browser/renderer_interface_binders.cc
|
||||
+++ content/browser/renderer_interface_binders.cc
|
||||
@@ -112,7 +112,7 @@ void RendererInterfaceBinders::InitializeParameterizedBinderRegistry() {
|
||||
parameterized_binder_registry_.AddInterface(
|
||||
base::Bind([](payments::mojom::PaymentManagerRequest request,
|
||||
RenderProcessHost* host, const url::Origin& origin) {
|
||||
- static_cast<StoragePartitionImpl*>(host->GetStoragePartition())
|
||||
+ host->GetStoragePartition()
|
||||
->GetPaymentAppContext()
|
||||
->CreatePaymentManager(std::move(request));
|
||||
}));
|
||||
@@ -128,9 +128,10 @@ void RendererInterfaceBinders::InitializeParameterizedBinderRegistry() {
|
||||
parameterized_binder_registry_.AddInterface(
|
||||
base::Bind([](blink::mojom::NotificationServiceRequest request,
|
||||
RenderProcessHost* host, const url::Origin& origin) {
|
||||
- static_cast<StoragePartitionImpl*>(host->GetStoragePartition())
|
||||
- ->GetPlatformNotificationContext()
|
||||
- ->CreateService(host->GetID(), origin, std::move(request));
|
||||
+ static_cast<PlatformNotificationContextImpl*>(
|
||||
+ host->GetStoragePartition()
|
||||
+ ->GetPlatformNotificationContext())
|
||||
+ ->CreateService(host->GetID(), origin, std::move(request));
|
||||
}));
|
||||
}
|
||||
|
||||
diff --git content/browser/shared_worker/shared_worker_connector_impl.cc content/browser/shared_worker/shared_worker_connector_impl.cc
|
||||
index 4fb7fcdb85c9..bf0155992715 100644
|
||||
--- content/browser/shared_worker/shared_worker_connector_impl.cc
|
||||
+++ content/browser/shared_worker/shared_worker_connector_impl.cc
|
||||
@@ -23,20 +23,22 @@ void SharedWorkerConnectorImpl::Create(
|
||||
RenderProcessHost* host = RenderProcessHost::FromID(process_id);
|
||||
ResourceContext* resource_context =
|
||||
host->GetBrowserContext()->GetResourceContext();
|
||||
- StoragePartitionImpl* storage_partition_impl =
|
||||
- static_cast<StoragePartitionImpl*>(host->GetStoragePartition());
|
||||
+ StoragePartition* storage_partition_impl = host->GetStoragePartition();
|
||||
|
||||
// TODO(darin): Surely there can be a better way to extract a comparable
|
||||
// identifier from a StoragePartition instance.
|
||||
WorkerStoragePartition worker_storage_partition(
|
||||
storage_partition_impl->GetURLRequestContext(),
|
||||
storage_partition_impl->GetMediaURLRequestContext(),
|
||||
- storage_partition_impl->GetAppCacheService(),
|
||||
+ static_cast<ChromeAppCacheService*>(
|
||||
+ storage_partition_impl->GetAppCacheService()),
|
||||
storage_partition_impl->GetQuotaManager(),
|
||||
storage_partition_impl->GetFileSystemContext(),
|
||||
storage_partition_impl->GetDatabaseTracker(),
|
||||
- storage_partition_impl->GetIndexedDBContext(),
|
||||
- storage_partition_impl->GetServiceWorkerContext());
|
||||
+ static_cast<IndexedDBContextImpl*>(
|
||||
+ storage_partition_impl->GetIndexedDBContext()),
|
||||
+ static_cast<ServiceWorkerContextWrapper*>(
|
||||
+ storage_partition_impl->GetServiceWorkerContext()));
|
||||
|
||||
CreateInternal(process_id, frame_id, resource_context,
|
||||
worker_storage_partition, std::move(request));
|
||||
diff --git content/browser/shared_worker/shared_worker_service_impl.cc content/browser/shared_worker/shared_worker_service_impl.cc
|
||||
index ecf29e7851da..bba93010b3ad 100644
|
||||
--- content/browser/shared_worker/shared_worker_service_impl.cc
|
||||
+++ content/browser/shared_worker/shared_worker_service_impl.cc
|
||||
@@ -63,17 +63,19 @@ bool SharedWorkerServiceImpl::TerminateWorker(
|
||||
const url::Origin& constructor_origin,
|
||||
StoragePartition* storage_partition,
|
||||
ResourceContext* resource_context) {
|
||||
- StoragePartitionImpl* storage_partition_impl =
|
||||
- static_cast<StoragePartitionImpl*>(storage_partition);
|
||||
+ StoragePartition* storage_partition_impl = storage_partition;
|
||||
WorkerStoragePartitionId partition_id(WorkerStoragePartition(
|
||||
storage_partition_impl->GetURLRequestContext(),
|
||||
storage_partition_impl->GetMediaURLRequestContext(),
|
||||
- storage_partition_impl->GetAppCacheService(),
|
||||
+ static_cast<ChromeAppCacheService*>(
|
||||
+ storage_partition_impl->GetAppCacheService()),
|
||||
storage_partition_impl->GetQuotaManager(),
|
||||
storage_partition_impl->GetFileSystemContext(),
|
||||
storage_partition_impl->GetDatabaseTracker(),
|
||||
- storage_partition_impl->GetIndexedDBContext(),
|
||||
- storage_partition_impl->GetServiceWorkerContext()));
|
||||
+ static_cast<IndexedDBContextImpl*>(
|
||||
+ storage_partition_impl->GetIndexedDBContext()),
|
||||
+ static_cast<ServiceWorkerContextWrapper*>(
|
||||
+ storage_partition_impl->GetServiceWorkerContext())));
|
||||
|
||||
for (const auto& iter : worker_hosts_) {
|
||||
SharedWorkerHost* host = iter.second.get();
|
||||
diff --git content/browser/storage_partition_impl.h content/browser/storage_partition_impl.h
|
||||
index 6e62286f3f09..11a3cd5f07cb 100644
|
||||
index 54818f596e4c..58bd25f9bd24 100644
|
||||
--- content/browser/storage_partition_impl.h
|
||||
+++ content/browser/storage_partition_impl.h
|
||||
@@ -117,32 +117,31 @@ class CONTENT_EXPORT StoragePartitionImpl
|
||||
const base::Closure& callback) override;
|
||||
void Flush() override;
|
||||
@@ -119,13 +119,13 @@ class CONTENT_EXPORT StoragePartitionImpl
|
||||
void ClearBluetoothAllowedDevicesMapForTesting() override;
|
||||
-
|
||||
void SetNetworkFactoryForTesting(
|
||||
mojom::URLLoaderFactory* test_factory) override;
|
||||
- BackgroundFetchContext* GetBackgroundFetchContext();
|
||||
- BackgroundSyncContext* GetBackgroundSyncContext();
|
||||
- PaymentAppContextImpl* GetPaymentAppContext();
|
||||
@@ -477,6 +549,7 @@ index 6e62286f3f09..11a3cd5f07cb 100644
|
||||
|
||||
// mojom::StoragePartitionService interface.
|
||||
void OpenLocalStorage(
|
||||
@@ -136,18 +136,18 @@ class CONTENT_EXPORT StoragePartitionImpl
|
||||
const url::Origin& origin,
|
||||
mojo::InterfaceRequest<mojom::LevelDBWrapper> request) override;
|
||||
|
||||
@@ -500,7 +573,7 @@ index 6e62286f3f09..11a3cd5f07cb 100644
|
||||
auto& bindings_for_testing() { return bindings_; }
|
||||
|
||||
diff --git content/browser/streams/stream_context.cc content/browser/streams/stream_context.cc
|
||||
index b23d083c7342..49d52038a049 100644
|
||||
index 7aafca3aafcd..aac07962f6a5 100644
|
||||
--- content/browser/streams/stream_context.cc
|
||||
+++ content/browser/streams/stream_context.cc
|
||||
@@ -22,6 +22,11 @@ namespace content {
|
||||
@@ -528,12 +601,12 @@ index 075ae3e7431e..57fb5fd2c4a8 100644
|
||||
|
||||
void InitializeOnIOThread();
|
||||
diff --git content/browser/webui/web_ui_url_loader_factory.cc content/browser/webui/web_ui_url_loader_factory.cc
|
||||
index 579df51d8083..09298a8d042a 100644
|
||||
index 8996f11d328e..75b658f5a2d2 100644
|
||||
--- content/browser/webui/web_ui_url_loader_factory.cc
|
||||
+++ content/browser/webui/web_ui_url_loader_factory.cc
|
||||
@@ -19,13 +19,13 @@
|
||||
#include "content/browser/frame_host/render_frame_host_impl.h"
|
||||
@@ -20,13 +20,13 @@
|
||||
#include "content/browser/histogram_internals_url_loader.h"
|
||||
#include "content/browser/loader/global_routing_id.h"
|
||||
#include "content/browser/resource_context_impl.h"
|
||||
-#include "content/browser/storage_partition_impl.h"
|
||||
#include "content/browser/webui/network_error_url_loader.h"
|
||||
@@ -544,33 +617,25 @@ index 579df51d8083..09298a8d042a 100644
|
||||
#include "content/public/browser/render_process_host.h"
|
||||
+#include "content/public/browser/storage_partition.h"
|
||||
#include "content/public/browser/web_contents.h"
|
||||
#include "content/public/browser/web_contents_observer.h"
|
||||
#include "content/public/common/network_service.mojom.h"
|
||||
#include "content/public/common/url_constants.h"
|
||||
@@ -209,8 +209,8 @@ class WebUIURLLoaderFactory : public mojom::URLLoaderFactory,
|
||||
public:
|
||||
WebUIURLLoaderFactory(FrameTreeNode* ftn)
|
||||
: frame_tree_node_id_(ftn->frame_tree_node_id()),
|
||||
- storage_partition_(static_cast<StoragePartitionImpl*>(
|
||||
- ftn->current_frame_host()->GetProcess()->GetStoragePartition())) {
|
||||
+ storage_partition_(
|
||||
+ ftn->current_frame_host()->GetProcess()->GetStoragePartition()) {
|
||||
ftn->AddObserver(this);
|
||||
}
|
||||
|
||||
@@ -278,7 +278,7 @@ class WebUIURLLoaderFactory : public mojom::URLLoaderFactory,
|
||||
@@ -296,9 +296,8 @@ class WebUIURLLoaderFactory : public mojom::URLLoaderFactory,
|
||||
const std::string& scheme() const { return scheme_; }
|
||||
|
||||
private:
|
||||
int frame_tree_node_id_;
|
||||
- StoragePartitionImpl* storage_partition_;
|
||||
+ StoragePartition* storage_partition_;
|
||||
mojo::BindingSet<mojom::URLLoaderFactory> loader_factory_bindings_;
|
||||
- StoragePartitionImpl* GetStoragePartition() {
|
||||
- return static_cast<StoragePartitionImpl*>(
|
||||
- render_frame_host_->GetProcess()->GetStoragePartition());
|
||||
+ StoragePartition* GetStoragePartition() {
|
||||
+ return render_frame_host_->GetProcess()->GetStoragePartition();
|
||||
}
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(WebUIURLLoaderFactory);
|
||||
RenderFrameHost* render_frame_host_;
|
||||
diff --git content/public/browser/browser_context.h content/public/browser/browser_context.h
|
||||
index eff149812e0e..d0484fa48674 100644
|
||||
index f75be61ccdef..84f1063fb081 100644
|
||||
--- content/public/browser/browser_context.h
|
||||
+++ content/public/browser/browser_context.h
|
||||
@@ -194,6 +194,8 @@ class CONTENT_EXPORT BrowserContext : public base::SupportsUserData {
|
||||
@@ -200,6 +200,8 @@ class CONTENT_EXPORT BrowserContext : public base::SupportsUserData {
|
||||
|
||||
BrowserContext();
|
||||
|
||||
@@ -579,7 +644,7 @@ index eff149812e0e..d0484fa48674 100644
|
||||
~BrowserContext() override;
|
||||
|
||||
// Shuts down the storage partitions associated to this browser context.
|
||||
@@ -282,6 +284,14 @@ class CONTENT_EXPORT BrowserContext : public base::SupportsUserData {
|
||||
@@ -288,6 +290,14 @@ class CONTENT_EXPORT BrowserContext : public base::SupportsUserData {
|
||||
const base::FilePath& partition_path,
|
||||
bool in_memory) = 0;
|
||||
|
||||
@@ -595,18 +660,18 @@ index eff149812e0e..d0484fa48674 100644
|
||||
std::map<std::string, service_manager::EmbeddedServiceInfo>;
|
||||
|
||||
diff --git content/public/browser/storage_partition.h content/public/browser/storage_partition.h
|
||||
index c3c1aa9d5351..08555f42ac39 100644
|
||||
index fa9a14e82472..7ed0814308aa 100644
|
||||
--- content/public/browser/storage_partition.h
|
||||
+++ content/public/browser/storage_partition.h
|
||||
@@ -13,6 +13,7 @@
|
||||
#include "base/files/file_path.h"
|
||||
@@ -14,6 +14,7 @@
|
||||
#include "base/time/time.h"
|
||||
#include "content/common/content_export.h"
|
||||
#include "content/public/common/url_loader_factory.mojom.h"
|
||||
+#include "mojo/public/cpp/bindings/binding_set.h"
|
||||
#include "net/cookies/cookie_store.h"
|
||||
|
||||
class GURL;
|
||||
@@ -41,12 +42,20 @@ class DatabaseTracker;
|
||||
@@ -42,12 +43,20 @@ class DatabaseTracker;
|
||||
namespace content {
|
||||
|
||||
class AppCacheService;
|
||||
@@ -627,7 +692,7 @@ index c3c1aa9d5351..08555f42ac39 100644
|
||||
|
||||
#if !defined(OS_ANDROID)
|
||||
class HostZoomLevelContext;
|
||||
@@ -59,6 +68,11 @@ class NetworkContext;
|
||||
@@ -60,6 +69,11 @@ class NetworkContext;
|
||||
class URLLoaderFactory;
|
||||
}
|
||||
|
||||
@@ -639,7 +704,7 @@ index c3c1aa9d5351..08555f42ac39 100644
|
||||
// Defines what persistent state a child process can access.
|
||||
//
|
||||
// The StoragePartition defines the view each child process has of the
|
||||
@@ -91,6 +105,13 @@ class CONTENT_EXPORT StoragePartition {
|
||||
@@ -92,6 +106,13 @@ class CONTENT_EXPORT StoragePartition {
|
||||
virtual ZoomLevelDelegate* GetZoomLevelDelegate() = 0;
|
||||
#endif // !defined(OS_ANDROID)
|
||||
virtual PlatformNotificationContext* GetPlatformNotificationContext() = 0;
|
||||
@@ -653,9 +718,9 @@ index c3c1aa9d5351..08555f42ac39 100644
|
||||
|
||||
enum : uint32_t {
|
||||
REMOVE_DATA_MASK_APPCACHE = 1 << 0,
|
||||
@@ -196,6 +217,14 @@ class CONTENT_EXPORT StoragePartition {
|
||||
// Clear the bluetooth allowed devices map. For test use only.
|
||||
virtual void ClearBluetoothAllowedDevicesMapForTesting() = 0;
|
||||
@@ -200,6 +221,14 @@ class CONTENT_EXPORT StoragePartition {
|
||||
virtual void SetNetworkFactoryForTesting(
|
||||
mojom::URLLoaderFactory* test_factory) = 0;
|
||||
|
||||
+ virtual URLLoaderFactoryGetter* url_loader_factory_getter() = 0;
|
||||
+ virtual BrowserContext* browser_context() const = 0;
|
||||
@@ -669,10 +734,10 @@ index c3c1aa9d5351..08555f42ac39 100644
|
||||
virtual ~StoragePartition() {}
|
||||
};
|
||||
diff --git storage/browser/database/database_tracker.cc storage/browser/database/database_tracker.cc
|
||||
index 86fb9f41fc71..7a8be02473a3 100644
|
||||
index e4ee15fd49ab..5adc8867d6df 100644
|
||||
--- storage/browser/database/database_tracker.cc
|
||||
+++ storage/browser/database/database_tracker.cc
|
||||
@@ -495,7 +495,7 @@ bool DatabaseTracker::LazyInit() {
|
||||
@@ -492,7 +492,7 @@ bool DatabaseTracker::LazyInit() {
|
||||
meta_table_.reset(new sql::MetaTable());
|
||||
|
||||
is_initialized_ =
|
||||
|
@@ -39,10 +39,10 @@ index 0755f2752f1d..0322b8c638e7 100644
|
||||
virtual void MenuWillShow() {}
|
||||
|
||||
diff --git ui/gfx/render_text.cc ui/gfx/render_text.cc
|
||||
index 43603c028e5e..a06aaf037153 100644
|
||||
index cb77d5b27ccf..4abcb5712945 100644
|
||||
--- ui/gfx/render_text.cc
|
||||
+++ ui/gfx/render_text.cc
|
||||
@@ -495,6 +495,14 @@ void RenderText::SetElideBehavior(ElideBehavior elide_behavior) {
|
||||
@@ -501,6 +501,14 @@ void RenderText::SetElideBehavior(ElideBehavior elide_behavior) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ index 43603c028e5e..a06aaf037153 100644
|
||||
void RenderText::SetDisplayRect(const Rect& r) {
|
||||
if (r != display_rect_) {
|
||||
display_rect_ = r;
|
||||
@@ -1433,6 +1441,19 @@ void RenderText::OnTextAttributeChanged() {
|
||||
@@ -1448,6 +1456,19 @@ void RenderText::OnTextAttributeChanged() {
|
||||
if (!multiline_ && replace_newline_chars_with_symbols_)
|
||||
base::ReplaceChars(layout_text_, kNewline, kNewlineSymbol, &layout_text_);
|
||||
|
||||
@@ -78,10 +78,10 @@ index 43603c028e5e..a06aaf037153 100644
|
||||
}
|
||||
|
||||
diff --git ui/gfx/render_text.h ui/gfx/render_text.h
|
||||
index fb9ab0f6cc85..17f182198b06 100644
|
||||
index 259f39b2825b..5b71cd6c6a46 100644
|
||||
--- ui/gfx/render_text.h
|
||||
+++ ui/gfx/render_text.h
|
||||
@@ -280,6 +280,10 @@ class GFX_EXPORT RenderText {
|
||||
@@ -283,6 +283,10 @@ class GFX_EXPORT RenderText {
|
||||
void SetElideBehavior(ElideBehavior elide_behavior);
|
||||
ElideBehavior elide_behavior() const { return elide_behavior_; }
|
||||
|
||||
@@ -92,9 +92,9 @@ index fb9ab0f6cc85..17f182198b06 100644
|
||||
const Rect& display_rect() const { return display_rect_; }
|
||||
void SetDisplayRect(const Rect& r);
|
||||
|
||||
@@ -833,6 +837,8 @@ class GFX_EXPORT RenderText {
|
||||
// The ratio of strike-through line thickness to text height.
|
||||
SkScalar strike_thickness_factor_;
|
||||
@@ -840,6 +844,8 @@ class GFX_EXPORT RenderText {
|
||||
// Extra spacing placed between glyphs; used for obscured text styling.
|
||||
int glyph_spacing_ = 0;
|
||||
|
||||
+ int draw_strings_flags_ = 0;
|
||||
+
|
||||
@@ -115,7 +115,7 @@ index 8ac475fa752c..ec58c2b28441 100644
|
||||
static constexpr int kInkDropSmallCornerRadius = 2;
|
||||
static constexpr int kInkDropLargeCornerRadius = 4;
|
||||
diff --git ui/views/controls/button/label_button.cc ui/views/controls/button/label_button.cc
|
||||
index 68be16e39a1d..8038f932444d 100644
|
||||
index 57e2b0a910f0..6a17ba24a7d3 100644
|
||||
--- ui/views/controls/button/label_button.cc
|
||||
+++ ui/views/controls/button/label_button.cc
|
||||
@@ -188,6 +188,7 @@ gfx::Size LabelButton::CalculatePreferredSize() const {
|
||||
@@ -124,9 +124,9 @@ index 68be16e39a1d..8038f932444d 100644
|
||||
label.SetShadows(label_->shadows());
|
||||
+ label.SetDrawStringsFlags(label_->draw_strings_flags());
|
||||
|
||||
if (style_ == STYLE_BUTTON && PlatformStyle::kDefaultLabelButtonHasBoldFont) {
|
||||
if (style_ == STYLE_BUTTON) {
|
||||
// Some text appears wider when rendered normally than when rendered bold.
|
||||
@@ -399,6 +400,12 @@ std::unique_ptr<views::InkDropHighlight> LabelButton::CreateInkDropHighlight()
|
||||
@@ -400,6 +401,12 @@ std::unique_ptr<views::InkDropHighlight> LabelButton::CreateInkDropHighlight()
|
||||
gfx::RectF(image()->GetMirroredBounds()).CenterPoint());
|
||||
}
|
||||
|
||||
@@ -140,7 +140,7 @@ index 68be16e39a1d..8038f932444d 100644
|
||||
const gfx::Size previous_image_size(image_->GetPreferredSize());
|
||||
UpdateImage();
|
||||
diff --git ui/views/controls/button/label_button.h ui/views/controls/button/label_button.h
|
||||
index bc5190a4bc76..053cb7ce900b 100644
|
||||
index 259c355b1d2d..d86f909d95ed 100644
|
||||
--- ui/views/controls/button/label_button.h
|
||||
+++ ui/views/controls/button/label_button.h
|
||||
@@ -105,6 +105,9 @@ class VIEWS_EXPORT LabelButton : public Button, public NativeThemeDelegate {
|
||||
@@ -211,7 +211,7 @@ index e38200b8a43a..f40b079f82ec 100644
|
||||
// The time is used for simulating menu behavior for the menu button; that
|
||||
// is, if the menu is shown and the button is pressed, we need to close the
|
||||
diff --git ui/views/controls/label.cc ui/views/controls/label.cc
|
||||
index def97220e051..cbe1568cbda3 100644
|
||||
index df6851e8d212..8f5047f4aec7 100644
|
||||
--- ui/views/controls/label.cc
|
||||
+++ ui/views/controls/label.cc
|
||||
@@ -25,6 +25,7 @@
|
||||
@@ -243,7 +243,7 @@ index def97220e051..cbe1568cbda3 100644
|
||||
} // namespace
|
||||
|
||||
const char Label::kViewClassName[] = "Label";
|
||||
@@ -226,6 +241,15 @@ void Label::SetElideBehavior(gfx::ElideBehavior elide_behavior) {
|
||||
@@ -224,6 +239,15 @@ void Label::SetElideBehavior(gfx::ElideBehavior elide_behavior) {
|
||||
ResetLayout();
|
||||
}
|
||||
|
||||
@@ -259,7 +259,7 @@ index def97220e051..cbe1568cbda3 100644
|
||||
void Label::SetTooltipText(const base::string16& tooltip_text) {
|
||||
DCHECK(handles_tooltips_);
|
||||
tooltip_text_ = tooltip_text;
|
||||
@@ -453,7 +477,19 @@ std::unique_ptr<gfx::RenderText> Label::CreateRenderText(
|
||||
@@ -460,7 +484,19 @@ std::unique_ptr<gfx::RenderText> Label::CreateRenderText(
|
||||
render_text->SetFontList(font_list());
|
||||
render_text->set_shadows(shadows());
|
||||
render_text->SetCursorEnabled(false);
|
||||
@@ -304,10 +304,10 @@ index ab6487ee6a60..0b105a658e8f 100644
|
||||
// TODO(ckocagil): Remove is_first_paint_text_ before crbug.com/441028 is
|
||||
// closed.
|
||||
diff --git ui/views/controls/menu/menu_controller.cc ui/views/controls/menu/menu_controller.cc
|
||||
index 2f78dfd30849..313a26e85e3b 100644
|
||||
index 9389f25f034d..60f546b55951 100644
|
||||
--- ui/views/controls/menu/menu_controller.cc
|
||||
+++ ui/views/controls/menu/menu_controller.cc
|
||||
@@ -2262,8 +2262,13 @@ MenuItemView* MenuController::FindNextSelectableMenuItem(
|
||||
@@ -2261,8 +2261,13 @@ MenuItemView* MenuController::FindNextSelectableMenuItem(
|
||||
|
||||
void MenuController::OpenSubmenuChangeSelectionIfCan() {
|
||||
MenuItemView* item = pending_state_.item;
|
||||
@@ -322,7 +322,7 @@ index 2f78dfd30849..313a26e85e3b 100644
|
||||
MenuItemView* to_select = NULL;
|
||||
if (item->GetSubmenu()->GetMenuItemCount() > 0)
|
||||
to_select = FindInitialSelectableMenuItem(item, INCREMENT_SELECTION_DOWN);
|
||||
@@ -2278,8 +2283,10 @@ void MenuController::OpenSubmenuChangeSelectionIfCan() {
|
||||
@@ -2277,8 +2282,10 @@ void MenuController::OpenSubmenuChangeSelectionIfCan() {
|
||||
void MenuController::CloseSubmenu() {
|
||||
MenuItemView* item = state_.item;
|
||||
DCHECK(item);
|
||||
@@ -521,7 +521,7 @@ index 0ac493c3c6a0..741769e90eb0 100644
|
||||
void WillHideMenu(MenuItemView* menu) override;
|
||||
void OnMenuClosed(MenuItemView* menu) override;
|
||||
diff --git ui/views/controls/menu/menu_scroll_view_container.cc ui/views/controls/menu/menu_scroll_view_container.cc
|
||||
index 08ba198141b2..595b3750c544 100644
|
||||
index fc9e3426f7c6..d0513a05eff1 100644
|
||||
--- ui/views/controls/menu/menu_scroll_view_container.cc
|
||||
+++ ui/views/controls/menu/menu_scroll_view_container.cc
|
||||
@@ -184,6 +184,11 @@ MenuScrollViewContainer::MenuScrollViewContainer(SubmenuView* content_view)
|
||||
@@ -537,10 +537,10 @@ index 08ba198141b2..595b3750c544 100644
|
||||
content_view_->GetMenuItem()->GetMenuController()->GetAnchorPosition());
|
||||
|
||||
diff --git ui/views/test/ui_controls_factory_desktop_aurax11.cc ui/views/test/ui_controls_factory_desktop_aurax11.cc
|
||||
index 534e0c4cb41d..974d82da99cb 100644
|
||||
index 875ac82283b3..44424b2ce138 100644
|
||||
--- ui/views/test/ui_controls_factory_desktop_aurax11.cc
|
||||
+++ ui/views/test/ui_controls_factory_desktop_aurax11.cc
|
||||
@@ -147,10 +147,6 @@ class UIControlsDesktopX11 : public UIControlsAura {
|
||||
@@ -140,10 +140,6 @@ class UIControlsDesktopX11 : public UIControlsAura {
|
||||
aura::test::QueryLatestMousePositionRequestInHost(host);
|
||||
host->ConvertPixelsToDIP(&root_current_location);
|
||||
|
||||
@@ -552,7 +552,7 @@ index 534e0c4cb41d..974d82da99cb 100644
|
||||
// Move the cursor because EnterNotify/LeaveNotify are generated with the
|
||||
// current mouse position as a result of XGrabPointer()
|
||||
diff --git ui/views/view.h ui/views/view.h
|
||||
index bfacdb72edaa..b7684349c0cc 100644
|
||||
index da4b110ecec8..f03291dcd330 100644
|
||||
--- ui/views/view.h
|
||||
+++ ui/views/view.h
|
||||
@@ -18,6 +18,7 @@
|
||||
|
@@ -1,9 +1,9 @@
|
||||
diff --git content/browser/renderer_host/render_widget_host_view_base.cc content/browser/renderer_host/render_widget_host_view_base.cc
|
||||
index 964578b4d170..6a3f3c347031 100644
|
||||
index 34248e7b2ef8..8ed9c3759202 100644
|
||||
--- content/browser/renderer_host/render_widget_host_view_base.cc
|
||||
+++ content/browser/renderer_host/render_widget_host_view_base.cc
|
||||
@@ -301,6 +301,14 @@ void RenderWidgetHostViewBase::FocusedNodeTouched(
|
||||
DVLOG(1) << "FocusedNodeTouched: " << editable;
|
||||
@@ -326,6 +326,14 @@ void RenderWidgetHostViewBase::GetScreenInfo(ScreenInfo* screen_info) {
|
||||
host->delegate()->GetScreenInfo(screen_info);
|
||||
}
|
||||
|
||||
+void RenderWidgetHostViewBase::SetHasExternalParent(bool val) {
|
||||
@@ -18,10 +18,10 @@ index 964578b4d170..6a3f3c347031 100644
|
||||
return renderer_frame_number_;
|
||||
}
|
||||
diff --git content/browser/renderer_host/render_widget_host_view_base.h content/browser/renderer_host/render_widget_host_view_base.h
|
||||
index 1764ea8c31cd..c772ae729d08 100644
|
||||
index aac5858b18d8..652b07955fe8 100644
|
||||
--- content/browser/renderer_host/render_widget_host_view_base.h
|
||||
+++ content/browser/renderer_host/render_widget_host_view_base.h
|
||||
@@ -82,6 +82,7 @@ class BrowserAccessibilityManager;
|
||||
@@ -83,6 +83,7 @@ class BrowserAccessibilityManager;
|
||||
class CursorManager;
|
||||
class RenderWidgetHostImpl;
|
||||
class RenderWidgetHostViewBaseObserver;
|
||||
@@ -29,7 +29,7 @@ index 1764ea8c31cd..c772ae729d08 100644
|
||||
class SyntheticGestureTarget;
|
||||
class TextInputManager;
|
||||
class TouchSelectionControllerClientManager;
|
||||
@@ -99,6 +100,9 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
|
||||
@@ -100,6 +101,9 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
|
||||
float current_device_scale_factor() const {
|
||||
return current_device_scale_factor_;
|
||||
}
|
||||
@@ -39,16 +39,16 @@ index 1764ea8c31cd..c772ae729d08 100644
|
||||
|
||||
// Returns the focused RenderWidgetHost inside this |view|'s RWH.
|
||||
RenderWidgetHostImpl* GetFocusedWidget() const;
|
||||
@@ -128,6 +132,8 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
|
||||
void EndFrameSubscription() override;
|
||||
@@ -130,6 +134,8 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
|
||||
void FocusedNodeTouched(const gfx::Point& location_dips_screen,
|
||||
bool editable) override;
|
||||
void GetScreenInfo(ScreenInfo* screen_info) override;
|
||||
+ void SetHasExternalParent(bool val) override;
|
||||
+ bool HasExternalParent() const override;
|
||||
TouchSelectionControllerClientManager*
|
||||
GetTouchSelectionControllerClientManager() override;
|
||||
|
||||
@@ -376,6 +382,12 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
|
||||
@@ -396,6 +402,12 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
|
||||
// helps to position the full screen widget on the correct monitor.
|
||||
virtual void InitAsFullscreen(RenderWidgetHostView* reference_host_view) = 0;
|
||||
|
||||
@@ -61,7 +61,7 @@ index 1764ea8c31cd..c772ae729d08 100644
|
||||
// Sets the cursor for this view to the one associated with the specified
|
||||
// cursor_type.
|
||||
virtual void UpdateCursor(const WebCursor& cursor) = 0;
|
||||
@@ -519,6 +531,10 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
|
||||
@@ -542,6 +554,10 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
|
||||
|
||||
WebContentsAccessibility* web_contents_accessibility_;
|
||||
|
||||
@@ -73,7 +73,7 @@ index 1764ea8c31cd..c772ae729d08 100644
|
||||
#if defined(USE_AURA)
|
||||
void OnDidScheduleEmbed(int routing_id,
|
||||
diff --git content/browser/renderer_host/render_widget_host_view_event_handler.cc content/browser/renderer_host/render_widget_host_view_event_handler.cc
|
||||
index 02614b2e7eff..38c207888aba 100644
|
||||
index 8302a8563d85..7ae0a870071c 100644
|
||||
--- content/browser/renderer_host/render_widget_host_view_event_handler.cc
|
||||
+++ content/browser/renderer_host/render_widget_host_view_event_handler.cc
|
||||
@@ -28,6 +28,10 @@
|
||||
@@ -87,7 +87,7 @@ index 02614b2e7eff..38c207888aba 100644
|
||||
#if defined(OS_WIN)
|
||||
#include "content/browser/frame_host/render_frame_host_impl.h"
|
||||
#include "content/public/common/context_menu_params.h"
|
||||
@@ -850,6 +854,14 @@ void RenderWidgetHostViewEventHandler::SetKeyboardFocus() {
|
||||
@@ -857,6 +861,14 @@ void RenderWidgetHostViewEventHandler::SetKeyboardFocus() {
|
||||
::SetFocus(hwnd);
|
||||
}
|
||||
}
|
||||
@@ -103,12 +103,12 @@ index 02614b2e7eff..38c207888aba 100644
|
||||
// TODO(wjmaclean): can host_ ever be null?
|
||||
if (host_ && set_focus_on_mouse_down_or_key_event_) {
|
||||
diff --git content/public/browser/render_widget_host_view.h content/public/browser/render_widget_host_view.h
|
||||
index 995f917d9ebc..dbbd8833b6fe 100644
|
||||
index 6aa5a869ddc3..e00559a2958a 100644
|
||||
--- content/public/browser/render_widget_host_view.h
|
||||
+++ content/public/browser/render_widget_host_view.h
|
||||
@@ -236,6 +236,14 @@ class CONTENT_EXPORT RenderWidgetHostView {
|
||||
// when the value has changed. Views must initially default to false.
|
||||
virtual void SetNeedsBeginFrames(bool needs_begin_frames) = 0;
|
||||
@@ -248,6 +248,14 @@ class CONTENT_EXPORT RenderWidgetHostView {
|
||||
// This method returns the ScreenInfo used by the view to render.
|
||||
virtual void GetScreenInfo(ScreenInfo* screen_info) = 0;
|
||||
|
||||
+ // Set whether the widget has a external parent view/window outside of the
|
||||
+ // Chromium-controlled view/window hierarchy.
|
||||
@@ -135,7 +135,7 @@ index f772f64d656e..7d13f9f81b6c 100644
|
||||
return host ? host->GetAcceleratedWidget() : NULL;
|
||||
}
|
||||
diff --git ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
|
||||
index 8e0c55fbba08..49e519244c97 100644
|
||||
index 2128b18525f1..66420b860fc1 100644
|
||||
--- ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
|
||||
+++ ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
|
||||
@@ -84,6 +84,7 @@ DesktopWindowTreeHostWin::DesktopWindowTreeHostWin(
|
||||
@@ -160,7 +160,7 @@ index 8e0c55fbba08..49e519244c97 100644
|
||||
|
||||
remove_standard_frame_ = params.remove_standard_frame;
|
||||
has_non_client_view_ = Widget::RequiresNonClientView(params.type);
|
||||
@@ -829,11 +834,15 @@ void DesktopWindowTreeHostWin::HandleFrameChanged() {
|
||||
@@ -832,11 +837,15 @@ void DesktopWindowTreeHostWin::HandleFrameChanged() {
|
||||
}
|
||||
|
||||
void DesktopWindowTreeHostWin::HandleNativeFocus(HWND last_focused_window) {
|
||||
@@ -194,10 +194,10 @@ index db66147f0e9c..2b9bdfa2ec53 100644
|
||||
// a reference.
|
||||
corewm::TooltipWin* tooltip_;
|
||||
diff --git ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc
|
||||
index ebb251545434..14f1320470cd 100644
|
||||
index 88486500f8d8..b1743e330a3d 100644
|
||||
--- ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc
|
||||
+++ ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc
|
||||
@@ -152,6 +152,7 @@ DesktopWindowTreeHostX11::DesktopWindowTreeHostX11(
|
||||
@@ -147,6 +147,7 @@ DesktopWindowTreeHostX11::DesktopWindowTreeHostX11(
|
||||
use_native_frame_(false),
|
||||
should_maximize_after_map_(false),
|
||||
use_argb_visual_(false),
|
||||
@@ -205,7 +205,7 @@ index ebb251545434..14f1320470cd 100644
|
||||
drag_drop_client_(NULL),
|
||||
native_widget_delegate_(native_widget_delegate),
|
||||
desktop_native_widget_aura_(desktop_native_widget_aura),
|
||||
@@ -165,6 +166,7 @@ DesktopWindowTreeHostX11::DesktopWindowTreeHostX11(
|
||||
@@ -160,6 +161,7 @@ DesktopWindowTreeHostX11::DesktopWindowTreeHostX11(
|
||||
has_window_focus_(false),
|
||||
has_pointer_focus_(false),
|
||||
modal_dialog_counter_(0),
|
||||
@@ -213,7 +213,7 @@ index ebb251545434..14f1320470cd 100644
|
||||
close_widget_factory_(this),
|
||||
weak_factory_(this) {}
|
||||
|
||||
@@ -200,6 +202,8 @@ std::vector<aura::Window*> DesktopWindowTreeHostX11::GetAllOpenWindows() {
|
||||
@@ -195,6 +197,8 @@ std::vector<aura::Window*> DesktopWindowTreeHostX11::GetAllOpenWindows() {
|
||||
}
|
||||
|
||||
gfx::Rect DesktopWindowTreeHostX11::GetX11RootWindowBounds() const {
|
||||
@@ -222,17 +222,17 @@ index ebb251545434..14f1320470cd 100644
|
||||
return bounds_in_pixels_;
|
||||
}
|
||||
|
||||
@@ -511,7 +515,8 @@ void DesktopWindowTreeHostX11::CloseNow() {
|
||||
@@ -506,7 +510,8 @@ void DesktopWindowTreeHostX11::CloseNow() {
|
||||
// Actually free our native resources.
|
||||
if (ui::PlatformEventSource::GetInstance())
|
||||
ui::PlatformEventSource::GetInstance()->RemovePlatformEventDispatcher(this);
|
||||
- XDestroyWindow(xdisplay_, xwindow_);
|
||||
+ if (!xwindow_destroyed_)
|
||||
+ XDestroyWindow(xdisplay_, xwindow_);
|
||||
xwindow_ = None;
|
||||
xwindow_ = x11::None;
|
||||
|
||||
desktop_native_widget_aura_->OnHostClosed();
|
||||
@@ -652,6 +657,8 @@ void DesktopWindowTreeHostX11::GetWindowPlacement(
|
||||
@@ -647,6 +652,8 @@ void DesktopWindowTreeHostX11::GetWindowPlacement(
|
||||
}
|
||||
|
||||
gfx::Rect DesktopWindowTreeHostX11::GetWindowBoundsInScreen() const {
|
||||
@@ -241,7 +241,7 @@ index ebb251545434..14f1320470cd 100644
|
||||
return ToDIPRect(bounds_in_pixels_);
|
||||
}
|
||||
|
||||
@@ -1247,6 +1254,8 @@ void DesktopWindowTreeHostX11::SetBoundsInPixels(
|
||||
@@ -1243,6 +1250,8 @@ void DesktopWindowTreeHostX11::SetBoundsInPixels(
|
||||
}
|
||||
|
||||
gfx::Point DesktopWindowTreeHostX11::GetLocationOnScreenInPixels() const {
|
||||
@@ -250,15 +250,15 @@ index ebb251545434..14f1320470cd 100644
|
||||
return bounds_in_pixels_.origin();
|
||||
}
|
||||
|
||||
@@ -1339,7 +1348,6 @@ void DesktopWindowTreeHostX11::InitX11Window(
|
||||
@@ -1335,7 +1344,6 @@ void DesktopWindowTreeHostX11::InitX11Window(
|
||||
::Atom window_type;
|
||||
switch (params.type) {
|
||||
case Widget::InitParams::TYPE_MENU:
|
||||
- swa.override_redirect = True;
|
||||
- swa.override_redirect = x11::True;
|
||||
window_type = gfx::GetAtom("_NET_WM_WINDOW_TYPE_MENU");
|
||||
break;
|
||||
case Widget::InitParams::TYPE_TOOLTIP:
|
||||
@@ -1395,9 +1403,15 @@ void DesktopWindowTreeHostX11::InitX11Window(
|
||||
@@ -1391,9 +1399,15 @@ void DesktopWindowTreeHostX11::InitX11Window(
|
||||
attribute_mask |= CWBorderPixel;
|
||||
swa.border_pixel = 0;
|
||||
|
||||
@@ -275,7 +275,7 @@ index ebb251545434..14f1320470cd 100644
|
||||
bounds_in_pixels_.y(), bounds_in_pixels_.width(),
|
||||
bounds_in_pixels_.height(),
|
||||
0, // border width
|
||||
@@ -2012,6 +2026,10 @@ uint32_t DesktopWindowTreeHostX11::DispatchEvent(
|
||||
@@ -2010,6 +2024,10 @@ uint32_t DesktopWindowTreeHostX11::DispatchEvent(
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -287,10 +287,10 @@ index ebb251545434..14f1320470cd 100644
|
||||
case FocusOut:
|
||||
OnFocusEvent(xev->type == FocusIn, event->xfocus.mode,
|
||||
diff --git ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h
|
||||
index a47b80fe8a82..624ac7764c83 100644
|
||||
index fcf87700458c..9aecc0e48939 100644
|
||||
--- ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h
|
||||
+++ ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h
|
||||
@@ -86,6 +86,12 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
|
||||
@@ -84,6 +84,12 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
|
||||
// Disables event listening to make |dialog| modal.
|
||||
std::unique_ptr<base::Closure> DisableEventListening();
|
||||
|
||||
@@ -303,7 +303,7 @@ index a47b80fe8a82..624ac7764c83 100644
|
||||
protected:
|
||||
// Overridden from DesktopWindowTreeHost:
|
||||
void Init(aura::Window* content_window,
|
||||
@@ -308,6 +314,9 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
|
||||
@@ -301,6 +307,9 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
|
||||
// The bounds of |xwindow_|.
|
||||
gfx::Rect bounds_in_pixels_;
|
||||
|
||||
@@ -313,7 +313,7 @@ index a47b80fe8a82..624ac7764c83 100644
|
||||
// Whenever the bounds are set, we keep the previous set of bounds around so
|
||||
// we can have a better chance of getting the real
|
||||
// |restored_bounds_in_pixels_|. Window managers tend to send a Configure
|
||||
@@ -347,6 +356,10 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
|
||||
@@ -340,6 +349,10 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
|
||||
// Whether we used an ARGB visual for our window.
|
||||
bool use_argb_visual_;
|
||||
|
||||
@@ -324,7 +324,7 @@ index a47b80fe8a82..624ac7764c83 100644
|
||||
DesktopDragDropClientAuraX11* drag_drop_client_;
|
||||
|
||||
std::unique_ptr<ui::EventHandler> x11_non_client_event_filter_;
|
||||
@@ -434,6 +447,9 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
|
||||
@@ -427,6 +440,9 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
|
||||
|
||||
uint32_t modal_dialog_counter_;
|
||||
|
||||
@@ -335,7 +335,7 @@ index a47b80fe8a82..624ac7764c83 100644
|
||||
base::WeakPtrFactory<DesktopWindowTreeHostX11> weak_factory_;
|
||||
|
||||
diff --git ui/views/widget/widget.cc ui/views/widget/widget.cc
|
||||
index 8911591f9afa..a0103f5aeb99 100644
|
||||
index d685bf4f40e3..2e22ba96827e 100644
|
||||
--- ui/views/widget/widget.cc
|
||||
+++ ui/views/widget/widget.cc
|
||||
@@ -130,6 +130,7 @@ Widget::InitParams::InitParams(Type type)
|
||||
@@ -427,10 +427,10 @@ index 163e4b54b033..58f594db5019 100644
|
||||
if (native_widget_delegate->IsDialogBox()) {
|
||||
*style |= DS_MODALFRAME;
|
||||
diff --git ui/views/win/hwnd_message_handler.cc ui/views/win/hwnd_message_handler.cc
|
||||
index 9776325defc8..f86f1409bdd2 100644
|
||||
index 60c6c0e235ea..7a08a49320a2 100644
|
||||
--- ui/views/win/hwnd_message_handler.cc
|
||||
+++ ui/views/win/hwnd_message_handler.cc
|
||||
@@ -2664,8 +2664,12 @@ LRESULT HWNDMessageHandler::HandleMouseEventInternal(UINT message,
|
||||
@@ -2665,8 +2665,12 @@ LRESULT HWNDMessageHandler::HandleMouseEventInternal(UINT message,
|
||||
active_mouse_tracking_flags_ = 0;
|
||||
} else if (event.type() == ui::ET_MOUSEWHEEL) {
|
||||
// Reroute the mouse wheel to the window under the pointer if applicable.
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git content/browser/web_contents/web_contents_impl.cc content/browser/web_contents/web_contents_impl.cc
|
||||
index 7297db47cf2d..d47c44680415 100644
|
||||
index c1ae2a911735..e45e3e388a5e 100644
|
||||
--- content/browser/web_contents/web_contents_impl.cc
|
||||
+++ content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -1762,6 +1762,12 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) {
|
||||
@@ -1783,6 +1783,12 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) {
|
||||
std::string unique_name;
|
||||
frame_tree_.root()->SetFrameName(params.main_frame_name, unique_name);
|
||||
|
||||
@@ -15,15 +15,15 @@ index 7297db47cf2d..d47c44680415 100644
|
||||
WebContentsViewDelegate* delegate =
|
||||
GetContentClient()->browser()->GetWebContentsViewDelegate(this);
|
||||
|
||||
@@ -1772,6 +1778,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) {
|
||||
view_.reset(CreateWebContentsView(this, delegate,
|
||||
&render_view_host_delegate_view_));
|
||||
@@ -1837,6 +1843,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) {
|
||||
GetRenderViewHost()->DispatchRenderViewCreated();
|
||||
GetRenderManager()->current_frame_host()->SetRenderFrameCreated(true);
|
||||
}
|
||||
+ }
|
||||
|
||||
if (browser_plugin_guest_ && !GuestMode::IsCrossProcessFrameGuest(this)) {
|
||||
view_.reset(new WebContentsViewGuest(this, browser_plugin_guest_.get(),
|
||||
@@ -2340,6 +2347,15 @@ void WebContentsImpl::CreateNewWindow(
|
||||
// Create the renderer process in advance if requested.
|
||||
if (params.initialize_renderer) {
|
||||
@@ -2349,6 +2356,15 @@ void WebContentsImpl::CreateNewWindow(
|
||||
create_params.renderer_initiated_creation =
|
||||
main_frame_route_id != MSG_ROUTING_NONE;
|
||||
|
||||
@@ -36,10 +36,10 @@ index 7297db47cf2d..d47c44680415 100644
|
||||
+ &create_params.delegate_view);
|
||||
+ }
|
||||
+
|
||||
WebContentsImpl* new_contents = NULL;
|
||||
WebContentsImpl* new_contents = nullptr;
|
||||
if (!is_guest) {
|
||||
create_params.context = view_->GetNativeView();
|
||||
@@ -2369,7 +2385,7 @@ void WebContentsImpl::CreateNewWindow(
|
||||
@@ -2378,7 +2394,7 @@ void WebContentsImpl::CreateNewWindow(
|
||||
// TODO(brettw): It seems bogus that we have to call this function on the
|
||||
// newly created object and give it one of its own member variables.
|
||||
new_view->CreateViewForWidget(
|
||||
@@ -48,7 +48,7 @@ index 7297db47cf2d..d47c44680415 100644
|
||||
}
|
||||
// Save the created window associated with the route so we can show it
|
||||
// later.
|
||||
@@ -5507,7 +5523,7 @@ InterstitialPageImpl* WebContentsImpl::GetInterstitialForRenderManager() {
|
||||
@@ -5546,7 +5562,7 @@ InterstitialPageImpl* WebContentsImpl::GetInterstitialForRenderManager() {
|
||||
void WebContentsImpl::CreateRenderWidgetHostViewForRenderManager(
|
||||
RenderViewHost* render_view_host) {
|
||||
RenderWidgetHostViewBase* rwh_view =
|
||||
@@ -58,26 +58,26 @@ index 7297db47cf2d..d47c44680415 100644
|
||||
// Now that the RenderView has been created, we need to tell it its size.
|
||||
if (rwh_view)
|
||||
diff --git content/public/browser/web_contents.cc content/public/browser/web_contents.cc
|
||||
index fa0afb545df9..d677b310e5ec 100644
|
||||
index 53d56abb35a3..d7b955f42ca5 100644
|
||||
--- content/public/browser/web_contents.cc
|
||||
+++ content/public/browser/web_contents.cc
|
||||
@@ -29,7 +29,9 @@ WebContents::CreateParams::CreateParams(BrowserContext* context,
|
||||
guest_delegate(nullptr),
|
||||
@@ -30,7 +30,9 @@ WebContents::CreateParams::CreateParams(BrowserContext* context,
|
||||
context(nullptr),
|
||||
renderer_initiated_creation(false),
|
||||
- initialize_renderer(false) {
|
||||
+ initialize_renderer(false),
|
||||
initialize_renderer(false),
|
||||
- starting_sandbox_flags(blink::WebSandboxFlags::kNone) {}
|
||||
+ starting_sandbox_flags(blink::WebSandboxFlags::kNone),
|
||||
+ view(nullptr),
|
||||
+ delegate_view(nullptr) {
|
||||
}
|
||||
+ delegate_view(nullptr) {}
|
||||
|
||||
WebContents::CreateParams::CreateParams(const CreateParams& other) = default;
|
||||
|
||||
diff --git content/public/browser/web_contents.h content/public/browser/web_contents.h
|
||||
index 453942537f6c..be871fbb677b 100644
|
||||
index d6252667ed68..83265f9b6b41 100644
|
||||
--- content/public/browser/web_contents.h
|
||||
+++ content/public/browser/web_contents.h
|
||||
@@ -68,9 +68,11 @@ class InterstitialPage;
|
||||
class PageState;
|
||||
@@ -68,9 +68,11 @@ class BrowserPluginGuestDelegate;
|
||||
class InterstitialPage;
|
||||
class RenderFrameHost;
|
||||
class RenderViewHost;
|
||||
+class RenderViewHostDelegateView;
|
||||
@@ -88,10 +88,10 @@ index 453942537f6c..be871fbb677b 100644
|
||||
struct CustomContextMenuContext;
|
||||
struct DropData;
|
||||
struct Manifest;
|
||||
@@ -170,6 +172,10 @@ class WebContents : public PageNavigator,
|
||||
// Note that the pre-created renderer process may not be used if the first
|
||||
// navigation requires a dedicated or privileged process, such as a WebUI.
|
||||
bool initialize_renderer;
|
||||
@@ -173,6 +175,10 @@ class WebContents : public PageNavigator,
|
||||
|
||||
// Sandboxing flags set on the new WebContents.
|
||||
blink::WebSandboxFlags starting_sandbox_flags;
|
||||
+
|
||||
+ // Optionally specify the view and delegate view.
|
||||
+ content::WebContentsView* view;
|
||||
@@ -100,12 +100,12 @@ index 453942537f6c..be871fbb677b 100644
|
||||
|
||||
// Creates a new WebContents.
|
||||
diff --git content/public/browser/web_contents_delegate.h content/public/browser/web_contents_delegate.h
|
||||
index 3f31a372ecbb..0958fe90bb31 100644
|
||||
index 37db677b7438..4f4a8574e47d 100644
|
||||
--- content/public/browser/web_contents_delegate.h
|
||||
+++ content/public/browser/web_contents_delegate.h
|
||||
@@ -44,11 +44,13 @@ class ColorChooser;
|
||||
@@ -43,11 +43,13 @@ namespace content {
|
||||
class ColorChooser;
|
||||
class JavaScriptDialogManager;
|
||||
class PageState;
|
||||
class RenderFrameHost;
|
||||
+class RenderViewHostDelegateView;
|
||||
class RenderWidgetHost;
|
||||
@@ -117,7 +117,7 @@ index 3f31a372ecbb..0958fe90bb31 100644
|
||||
struct ColorSuggestion;
|
||||
struct ContextMenuParams;
|
||||
struct DropData;
|
||||
@@ -318,6 +320,14 @@ class CONTENT_EXPORT WebContentsDelegate {
|
||||
@@ -308,6 +310,14 @@ class CONTENT_EXPORT WebContentsDelegate {
|
||||
const std::string& partition_id,
|
||||
SessionStorageNamespace* session_storage_namespace);
|
||||
|
||||
|
@@ -1,11 +1,11 @@
|
||||
diff --git third_party/WebKit/Source/core/dom/DOMImplementation.cpp third_party/WebKit/Source/core/dom/DOMImplementation.cpp
|
||||
index b26a7d6b8413..476b5c138555 100644
|
||||
index 1d861b036458..3b20c991659b 100644
|
||||
--- third_party/WebKit/Source/core/dom/DOMImplementation.cpp
|
||||
+++ third_party/WebKit/Source/core/dom/DOMImplementation.cpp
|
||||
@@ -242,10 +242,11 @@ Document* DOMImplementation::createDocument(const String& type,
|
||||
// For that reason, the origin must be retrieved directly from init.url().
|
||||
if (init.GetFrame()->IsMainFrame()) {
|
||||
RefPtr<SecurityOrigin> origin = SecurityOrigin::Create(init.Url());
|
||||
scoped_refptr<SecurityOrigin> origin = SecurityOrigin::Create(init.Url());
|
||||
- plugin_data = init.GetFrame()->GetPage()->GetPluginData(origin.get());
|
||||
+ plugin_data = init.GetFrame()->GetPage()->GetPluginData(true,
|
||||
+ origin.get());
|
||||
@@ -17,10 +17,10 @@ index b26a7d6b8413..476b5c138555 100644
|
||||
.Top()
|
||||
.GetSecurityContext()
|
||||
diff --git third_party/WebKit/Source/core/frame/LocalFrame.cpp third_party/WebKit/Source/core/frame/LocalFrame.cpp
|
||||
index bf29beabedf7..e45901940d91 100644
|
||||
index 123258b23cb2..f00869df94e3 100644
|
||||
--- third_party/WebKit/Source/core/frame/LocalFrame.cpp
|
||||
+++ third_party/WebKit/Source/core/frame/LocalFrame.cpp
|
||||
@@ -1026,7 +1026,7 @@ FrameResourceCoordinator* LocalFrame::GetFrameResourceCoordinator() {
|
||||
@@ -1046,7 +1046,7 @@ FrameResourceCoordinator* LocalFrame::GetFrameResourceCoordinator() {
|
||||
PluginData* LocalFrame::GetPluginData() const {
|
||||
if (!Loader().AllowPlugins(kNotAboutToInstantiatePlugin))
|
||||
return nullptr;
|
||||
@@ -30,10 +30,10 @@ index bf29beabedf7..e45901940d91 100644
|
||||
}
|
||||
|
||||
diff --git third_party/WebKit/Source/core/page/Page.cpp third_party/WebKit/Source/core/page/Page.cpp
|
||||
index 769fb58698a4..5372984b342a 100644
|
||||
index c6071e8ba68e..4304cc95ba2e 100644
|
||||
--- third_party/WebKit/Source/core/page/Page.cpp
|
||||
+++ third_party/WebKit/Source/core/page/Page.cpp
|
||||
@@ -126,7 +126,8 @@ Page::Page(PageClients& page_clients)
|
||||
@@ -129,7 +129,8 @@ Page::Page(PageClients& page_clients)
|
||||
overscroll_controller_(
|
||||
OverscrollController::Create(GetVisualViewport(), GetChromeClient())),
|
||||
main_frame_(nullptr),
|
||||
@@ -41,9 +41,9 @@ index 769fb58698a4..5372984b342a 100644
|
||||
+ plugin_data_main_frame_(nullptr),
|
||||
+ plugin_data_sub_frame_(nullptr),
|
||||
editor_client_(page_clients.editor_client),
|
||||
spell_checker_client_(page_clients.spell_checker_client),
|
||||
use_counter_(page_clients.chrome_client &&
|
||||
@@ -300,21 +301,38 @@ void Page::RefreshPlugins() {
|
||||
page_clients.chrome_client->IsSVGImageChromeClient()
|
||||
@@ -303,21 +304,38 @@ void Page::RefreshPlugins() {
|
||||
PluginData::RefreshBrowserSidePluginCache();
|
||||
}
|
||||
|
||||
@@ -91,7 +91,7 @@ index 769fb58698a4..5372984b342a 100644
|
||||
page->NotifyPluginsChanged();
|
||||
}
|
||||
}
|
||||
@@ -661,7 +679,8 @@ DEFINE_TRACE(Page) {
|
||||
@@ -675,7 +693,8 @@ void Page::Trace(blink::Visitor* visitor) {
|
||||
visitor->Trace(visual_viewport_);
|
||||
visitor->Trace(overscroll_controller_);
|
||||
visitor->Trace(main_frame_);
|
||||
@@ -102,7 +102,7 @@ index 769fb58698a4..5372984b342a 100644
|
||||
visitor->Trace(use_counter_);
|
||||
visitor->Trace(plugins_changed_observers_);
|
||||
diff --git third_party/WebKit/Source/core/page/Page.h third_party/WebKit/Source/core/page/Page.h
|
||||
index 0ba364b0a934..e9b79de58841 100644
|
||||
index 1a02eb31d52a..d7d2c372f0c9 100644
|
||||
--- third_party/WebKit/Source/core/page/Page.h
|
||||
+++ third_party/WebKit/Source/core/page/Page.h
|
||||
@@ -135,7 +135,8 @@ class CORE_EXPORT Page final : public GarbageCollectedFinalized<Page>,
|
||||
@@ -115,7 +115,7 @@ index 0ba364b0a934..e9b79de58841 100644
|
||||
|
||||
// Refreshes the browser-side plugin cache.
|
||||
static void RefreshPlugins();
|
||||
@@ -351,7 +352,8 @@ class CORE_EXPORT Page final : public GarbageCollectedFinalized<Page>,
|
||||
@@ -361,7 +362,8 @@ class CORE_EXPORT Page final : public GarbageCollectedFinalized<Page>,
|
||||
// longer needed.
|
||||
Member<Frame> main_frame_;
|
||||
|
||||
@@ -124,12 +124,12 @@ index 0ba364b0a934..e9b79de58841 100644
|
||||
+ Member<PluginData> plugin_data_sub_frame_;
|
||||
|
||||
EditorClient* const editor_client_;
|
||||
SpellCheckerClient* const spell_checker_client_;
|
||||
SpellCheckStatus spell_check_status_ = SpellCheckStatus::kAutomatic;
|
||||
diff --git third_party/WebKit/Source/platform/plugins/PluginData.cpp third_party/WebKit/Source/platform/plugins/PluginData.cpp
|
||||
index 5eb6af5fbdd5..eac85461c7de 100644
|
||||
index 385972d2e150..88a8e018b2e2 100644
|
||||
--- third_party/WebKit/Source/platform/plugins/PluginData.cpp
|
||||
+++ third_party/WebKit/Source/platform/plugins/PluginData.cpp
|
||||
@@ -79,16 +79,18 @@ DEFINE_TRACE(PluginData) {
|
||||
@@ -79,16 +79,18 @@ void PluginData::Trace(blink::Visitor* visitor) {
|
||||
// static
|
||||
void PluginData::RefreshBrowserSidePluginCache() {
|
||||
PluginListBuilder builder(nullptr);
|
||||
@@ -152,10 +152,10 @@ index 5eb6af5fbdd5..eac85461c7de 100644
|
||||
for (PluginInfo* plugin_info : plugins_) {
|
||||
for (MimeClassInfo* mime_class_info : plugin_info->mimes_)
|
||||
diff --git third_party/WebKit/Source/platform/plugins/PluginData.h third_party/WebKit/Source/platform/plugins/PluginData.h
|
||||
index 14a944467373..f4333c6a5f09 100644
|
||||
index c2bdba557a6b..039446cef015 100644
|
||||
--- third_party/WebKit/Source/platform/plugins/PluginData.h
|
||||
+++ third_party/WebKit/Source/platform/plugins/PluginData.h
|
||||
@@ -94,7 +94,7 @@ class PLATFORM_EXPORT PluginData final
|
||||
@@ -95,7 +95,7 @@ class PLATFORM_EXPORT PluginData final
|
||||
const HeapVector<Member<PluginInfo>>& Plugins() const { return plugins_; }
|
||||
const HeapVector<Member<MimeClassInfo>>& Mimes() const { return mimes_; }
|
||||
const SecurityOrigin* Origin() const { return main_frame_origin_.get(); }
|
||||
@@ -165,10 +165,10 @@ index 14a944467373..f4333c6a5f09 100644
|
||||
|
||||
bool SupportsMimeType(const String& mime_type) const;
|
||||
diff --git third_party/WebKit/public/platform/Platform.h third_party/WebKit/public/platform/Platform.h
|
||||
index 379b033facc4..fcea4c7171b7 100644
|
||||
index 09c2e1516512..00f634a16dc5 100644
|
||||
--- third_party/WebKit/public/platform/Platform.h
|
||||
+++ third_party/WebKit/public/platform/Platform.h
|
||||
@@ -369,6 +369,7 @@ class BLINK_PLATFORM_EXPORT Platform {
|
||||
@@ -377,6 +377,7 @@ class BLINK_PLATFORM_EXPORT Platform {
|
||||
// satisfy this call. mainFrameOrigin is used by the browser process to
|
||||
// filter plugins from the plugin list based on content settings.
|
||||
virtual void GetPluginList(bool refresh,
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git third_party/WebKit/Source/core/exported/WebViewImpl.cpp third_party/WebKit/Source/core/exported/WebViewImpl.cpp
|
||||
index 1cc7c6eb7182..67129b9719b5 100644
|
||||
index b73e62a0420f..b9b463b87031 100644
|
||||
--- third_party/WebKit/Source/core/exported/WebViewImpl.cpp
|
||||
+++ third_party/WebKit/Source/core/exported/WebViewImpl.cpp
|
||||
@@ -249,8 +249,13 @@ void WebView::SetUseExternalPopupMenus(bool use_external_popup_menus) {
|
||||
@@ -256,8 +256,13 @@ void WebView::SetUseExternalPopupMenus(bool use_external_popup_menus) {
|
||||
g_should_use_external_popup_menus = use_external_popup_menus;
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ index 1cc7c6eb7182..67129b9719b5 100644
|
||||
}
|
||||
|
||||
namespace {
|
||||
@@ -346,6 +351,7 @@ WebViewImpl::WebViewImpl(WebViewClient* client,
|
||||
@@ -352,6 +357,7 @@ WebViewImpl::WebViewImpl(WebViewClient* client,
|
||||
enable_fake_page_scale_animation_for_testing_(false),
|
||||
fake_page_scale_animation_page_scale_factor_(0),
|
||||
fake_page_scale_animation_use_anchor_(false),
|
||||
@@ -27,10 +27,10 @@ index 1cc7c6eb7182..67129b9719b5 100644
|
||||
suppress_next_keypress_event_(false),
|
||||
ime_accept_events_(true),
|
||||
diff --git third_party/WebKit/Source/core/exported/WebViewImpl.h third_party/WebKit/Source/core/exported/WebViewImpl.h
|
||||
index 820c1d2a8500..653c868a8444 100644
|
||||
index bfacefa1cf8b..9361917e0a3b 100644
|
||||
--- third_party/WebKit/Source/core/exported/WebViewImpl.h
|
||||
+++ third_party/WebKit/Source/core/exported/WebViewImpl.h
|
||||
@@ -108,7 +108,8 @@ class CORE_EXPORT WebViewImpl final
|
||||
@@ -107,7 +107,8 @@ class CORE_EXPORT WebViewImpl final
|
||||
static const WebInputEvent* CurrentInputEvent();
|
||||
// Returns true if popup menus should be rendered by the browser, false if
|
||||
// they should be rendered by WebKit (which is the default).
|
||||
@@ -40,7 +40,7 @@ index 820c1d2a8500..653c868a8444 100644
|
||||
|
||||
// WebWidget methods:
|
||||
void Close() override;
|
||||
@@ -613,6 +614,8 @@ class CORE_EXPORT WebViewImpl final
|
||||
@@ -608,6 +609,8 @@ class CORE_EXPORT WebViewImpl final
|
||||
float fake_page_scale_animation_page_scale_factor_;
|
||||
bool fake_page_scale_animation_use_anchor_;
|
||||
|
||||
@@ -50,10 +50,10 @@ index 820c1d2a8500..653c868a8444 100644
|
||||
TransformationMatrix device_emulation_transform_;
|
||||
|
||||
diff --git third_party/WebKit/Source/core/page/ChromeClientImpl.cpp third_party/WebKit/Source/core/page/ChromeClientImpl.cpp
|
||||
index a68ce2c67710..c85fd4cdfa43 100644
|
||||
index 129f3f1cb6c7..4dafa0474923 100644
|
||||
--- third_party/WebKit/Source/core/page/ChromeClientImpl.cpp
|
||||
+++ third_party/WebKit/Source/core/page/ChromeClientImpl.cpp
|
||||
@@ -774,7 +774,7 @@ PopupMenu* ChromeClientImpl::OpenPopupMenu(LocalFrame& frame,
|
||||
@@ -777,7 +777,7 @@ PopupMenu* ChromeClientImpl::OpenPopupMenu(LocalFrame& frame,
|
||||
return nullptr;
|
||||
|
||||
NotifyPopupOpeningObservers();
|
||||
@@ -63,10 +63,10 @@ index a68ce2c67710..c85fd4cdfa43 100644
|
||||
|
||||
DCHECK(RuntimeEnabledFeatures::PagePopupEnabled());
|
||||
diff --git third_party/WebKit/public/web/WebView.h third_party/WebKit/public/web/WebView.h
|
||||
index 03bfa9b85e7e..6f970fe0802e 100644
|
||||
index ccaade785697..61a406fb4ee1 100644
|
||||
--- third_party/WebKit/public/web/WebView.h
|
||||
+++ third_party/WebKit/public/web/WebView.h
|
||||
@@ -367,6 +367,7 @@ class WebView : protected WebWidget {
|
||||
@@ -361,6 +361,7 @@ class WebView : protected WebWidget {
|
||||
|
||||
// Sets whether select popup menus should be rendered by the browser.
|
||||
BLINK_EXPORT static void SetUseExternalPopupMenus(bool);
|
||||
|
@@ -1,5 +1,5 @@
|
||||
diff --git chrome/browser/feedback/system_logs/log_sources/chrome_internal_log_source.cc chrome/browser/feedback/system_logs/log_sources/chrome_internal_log_source.cc
|
||||
index 6b81e1e0f6c5..7509c2b18b47 100644
|
||||
index ff39e3e2b103..a507deeef179 100644
|
||||
--- chrome/browser/feedback/system_logs/log_sources/chrome_internal_log_source.cc
|
||||
+++ chrome/browser/feedback/system_logs/log_sources/chrome_internal_log_source.cc
|
||||
@@ -164,6 +164,10 @@ void ChromeInternalLogSource::Fetch(const SysLogsSourceCallback& callback) {
|
||||
@@ -14,10 +14,10 @@ index 6b81e1e0f6c5..7509c2b18b47 100644
|
||||
Profile* profile = ProfileManager::GetPrimaryUserProfile();
|
||||
if (!profile ||
|
||||
diff --git chrome/browser/ui/webui/net_internals/net_internals_ui.cc chrome/browser/ui/webui/net_internals/net_internals_ui.cc
|
||||
index 442ee5b2a91f..23c3feb4dea3 100644
|
||||
index c45df62f3d56..78b855d34d73 100644
|
||||
--- chrome/browser/ui/webui/net_internals/net_internals_ui.cc
|
||||
+++ chrome/browser/ui/webui/net_internals/net_internals_ui.cc
|
||||
@@ -515,41 +515,31 @@ void NetInternalsMessageHandler::OnClearBrowserCache(
|
||||
@@ -553,41 +553,31 @@ void NetInternalsMessageHandler::OnClearBrowserCache(
|
||||
void NetInternalsMessageHandler::OnGetPrerenderInfo(
|
||||
const base::ListValue* list) {
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
@@ -64,7 +64,7 @@ index 442ee5b2a91f..23c3feb4dea3 100644
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
@@ -629,9 +619,17 @@ void NetInternalsMessageHandler::IOThreadImpl::OnRendererReady(
|
||||
@@ -667,9 +657,17 @@ void NetInternalsMessageHandler::IOThreadImpl::OnRendererReady(
|
||||
|
||||
PrePopulateEventList();
|
||||
|
||||
@@ -85,7 +85,7 @@ index 442ee5b2a91f..23c3feb4dea3 100644
|
||||
}
|
||||
|
||||
void NetInternalsMessageHandler::IOThreadImpl::OnGetNetInfo(
|
||||
@@ -1105,7 +1103,8 @@ void NetInternalsMessageHandler::IOThreadImpl::PrePopulateEventList() {
|
||||
@@ -1181,7 +1179,8 @@ void NetInternalsMessageHandler::IOThreadImpl::PrePopulateEventList() {
|
||||
std::set<net::URLRequestContext*> contexts;
|
||||
for (const auto& getter : context_getters_)
|
||||
contexts.insert(getter->GetURLRequestContext());
|
||||
@@ -96,10 +96,10 @@ index 442ee5b2a91f..23c3feb4dea3 100644
|
||||
// Add entries for ongoing network objects.
|
||||
CreateNetLogEntriesForActiveObjects(contexts, this);
|
||||
diff --git content/browser/resource_context_impl.cc content/browser/resource_context_impl.cc
|
||||
index 141a08305332..b16b4d61988d 100644
|
||||
index 895a9367b85b..eeb9c6922a3c 100644
|
||||
--- content/browser/resource_context_impl.cc
|
||||
+++ content/browser/resource_context_impl.cc
|
||||
@@ -58,6 +58,10 @@ URLDataManagerBackend* GetURLDataManagerForResourceContext(
|
||||
@@ -57,6 +57,10 @@ URLDataManagerBackend* GetURLDataManagerForResourceContext(
|
||||
context->GetUserData(kURLDataManagerBackendKeyName));
|
||||
}
|
||||
|
||||
@@ -124,7 +124,7 @@ index 903cc543a242..5bd30ae82974 100644
|
||||
CONTENT_EXPORT void InitializeResourceContext(BrowserContext* browser_context);
|
||||
|
||||
diff --git content/browser/webui/url_data_manager.cc content/browser/webui/url_data_manager.cc
|
||||
index f45d227fe94a..32e37bd0a79e 100644
|
||||
index bdfc5d93765c..5464716aead4 100644
|
||||
--- content/browser/webui/url_data_manager.cc
|
||||
+++ content/browser/webui/url_data_manager.cc
|
||||
@@ -150,6 +150,11 @@ void URLDataManager::UpdateWebUIDataSource(
|
||||
|
@@ -1,8 +1,8 @@
|
||||
diff --git chrome/app/generated_resources.grd chrome/app/generated_resources.grd
|
||||
index acf5d47d03b2..1d126bb79633 100644
|
||||
index 991b42c3e041..ecdc0aaad9a5 100644
|
||||
--- chrome/app/generated_resources.grd
|
||||
+++ chrome/app/generated_resources.grd
|
||||
@@ -4807,7 +4807,7 @@ Keep your key file in a safe place. You will need it to create new versions of y
|
||||
@@ -4928,7 +4928,7 @@ Keep your key file in a safe place. You will need it to create new versions of y
|
||||
</message>
|
||||
</if>
|
||||
<message name="IDS_PLUGIN_BLOCKED_BY_POLICY" desc="The placeholder text for a plugin blocked by enterprise policy.">
|
||||
|
@@ -1,18 +1,18 @@
|
||||
diff --git content/common/sandbox_win.cc content/common/sandbox_win.cc
|
||||
index 3c8150376bbe..5d505838ec1d 100644
|
||||
--- content/common/sandbox_win.cc
|
||||
+++ content/common/sandbox_win.cc
|
||||
@@ -783,8 +783,11 @@ sandbox::ResultCode StartSandboxedProcess(
|
||||
diff --git services/service_manager/sandbox/win/sandbox_win.cc services/service_manager/sandbox/win/sandbox_win.cc
|
||||
index b66f6b27b4e4..56f69739320a 100644
|
||||
--- services/service_manager/sandbox/win/sandbox_win.cc
|
||||
+++ services/service_manager/sandbox/win/sandbox_win.cc
|
||||
@@ -757,8 +757,11 @@ sandbox::ResultCode SandboxWin::StartSandboxedProcess(
|
||||
#endif
|
||||
|
||||
// Post-startup mitigations.
|
||||
- mitigations = sandbox::MITIGATION_STRICT_HANDLE_CHECKS |
|
||||
- sandbox::MITIGATION_DLL_SEARCH_ORDER;
|
||||
+ mitigations = sandbox::MITIGATION_DLL_SEARCH_ORDER;
|
||||
+ if (!browser_command_line.HasSwitch("win-rt-app")) {
|
||||
+ if (!launcher_process_command_line.HasSwitch("win-rt-app")) {
|
||||
+ // Don't enable this mitigation in WinRT apps. See issue #2274.
|
||||
+ mitigations |= sandbox::MITIGATION_STRICT_HANDLE_CHECKS;
|
||||
+ }
|
||||
if (base::FeatureList::IsEnabled(features::kWinSboxForceMsSigned))
|
||||
mitigations |= sandbox::MITIGATION_FORCE_MS_SIGNED_BINS;
|
||||
|
||||
if (base::FeatureList::IsEnabled(
|
||||
service_manager::features::kWinSboxForceMsSigned) &&
|
||||
!cmd_line->HasSwitch(switches::kAllowThirdPartyModules)) {
|
||||
|
Reference in New Issue
Block a user