Commit 96bd993d authored by Marshall Greenblatt's avatar Marshall Greenblatt
Browse files

Update to Chromium version 69.0.3489.0 (#574445)

parent 8e9d736c
......@@ -7,5 +7,5 @@
# https://bitbucket.org/chromiumembedded/cef/wiki/BranchesAndBuilding
{
'chromium_checkout': 'refs/tags/69.0.3483.0',
'chromium_checkout': 'refs/tags/69.0.3489.0',
}
......@@ -224,6 +224,13 @@ bool CefBrowserHost::CreateBrowser(
return false;
}
if (windowInfo.windowless_rendering_enabled &&
!CefContext::Get()->settings().windowless_rendering_enabled) {
LOG(ERROR) << "Creating a windowless browser without setting "
"CefSettings.windowless_rendering_enabled may result in "
"reduced performance or runtime errors.";
}
// Create the browser on the UI thread.
CreateBrowserHelper* helper = new CreateBrowserHelper(
windowInfo, client, url, settings, request_context);
......
......@@ -16,6 +16,7 @@
#include "components/net_log/chrome_net_log.h"
#include "content/public/common/content_switches.h"
#include "services/network/public/cpp/network_switches.h"
#include "services/network/public/cpp/shared_url_loader_factory.h"
ChromeBrowserProcessStub::ChromeBrowserProcessStub()
: initialized_(false),
......@@ -144,6 +145,12 @@ ChromeBrowserProcessStub::system_request_context() {
return NULL;
}
scoped_refptr<network::SharedURLLoaderFactory>
ChromeBrowserProcessStub::shared_url_loader_factory() {
NOTREACHED();
return NULL;
}
variations::VariationsService* ChromeBrowserProcessStub::variations_service() {
NOTREACHED();
return NULL;
......
......@@ -55,6 +55,8 @@ class ChromeBrowserProcessStub : public BrowserProcess,
ProfileManager* profile_manager() override;
PrefService* local_state() override;
net::URLRequestContextGetter* system_request_context() override;
scoped_refptr<network::SharedURLLoaderFactory> shared_url_loader_factory()
override;
variations::VariationsService* variations_service() override;
BrowserProcessPlatformPart* platform_part() override;
extensions::EventRouterForwarder* extension_event_router_forwarder() override;
......
......@@ -46,7 +46,7 @@ void CefExtensionWebContentsObserver::RenderFrameCreated(
// are allowed to use chrome://resources/ URLs.
if ((extension->is_extension() || extension->is_platform_app()) &&
Manifest::IsComponentLocation(extension->location())) {
policy->GrantOrigin(
policy->GrantRequestOrigin(
process_id, url::Origin::Create(GURL(content::kChromeUIResourcesURL)));
}
}
......
......@@ -350,7 +350,7 @@ net::URLRequestContext* CefURLRequestContextGetterImpl::GetURLRequestContext() {
std::move(system_proxy_service));
io_state_->storage_->set_ssl_config_service(
std::make_unique<net::SSLConfigServiceDefaults>());
new net::SSLConfigServiceDefaults);
std::vector<std::string> supported_schemes;
supported_schemes.push_back("basic");
......
......@@ -137,10 +137,9 @@ void CefWebContentsViewOSR::RenderViewCreated(content::RenderViewHost* host) {
void CefWebContentsViewOSR::RenderViewReady() {}
void CefWebContentsViewOSR::RenderFrameSwappedIn(
content::RenderFrameHost* old_host,
content::RenderFrameHost* new_host,
bool is_main_frame) {}
void CefWebContentsViewOSR::RenderViewHostChanged(
content::RenderViewHost* old_host,
content::RenderViewHost* new_host) {}
void CefWebContentsViewOSR::SetOverscrollControllerEnabled(bool enabled) {}
......
......@@ -52,9 +52,8 @@ class CefWebContentsViewOSR : public content::WebContentsView,
void SetPageTitle(const base::string16& title) override;
void RenderViewCreated(content::RenderViewHost* host) override;
void RenderViewReady() override;
void RenderFrameSwappedIn(content::RenderFrameHost* old_host,
content::RenderFrameHost* new_host,
bool is_main_frame) override;
void RenderViewHostChanged(content::RenderViewHost* old_host,
content::RenderViewHost* new_host) override;
void SetOverscrollControllerEnabled(bool enabled) override;
#if defined(OS_MACOSX)
......
......@@ -31,7 +31,6 @@
#include "content/browser/browser_process_sub_thread.h"
#include "content/public/browser/browser_main_runner.h"
#include "content/public/browser/render_process_host.h"
#include "content/public/common/content_features.h"
#include "content/public/common/content_switches.h"
#include "content/public/common/main_function_params.h"
#include "extensions/common/constants.h"
......@@ -244,12 +243,9 @@ bool IsScaleFactorSupported(ui::ScaleFactor scale_factor) {
// Used to run the UI on a separate thread.
class CefUIThread : public base::Thread {
public:
CefUIThread(
const content::MainFunctionParams& main_function_params,
std::unique_ptr<content::BrowserProcessSubThread> service_manager_thread)
CefUIThread(const content::MainFunctionParams& main_function_params)
: base::Thread("CefUIThread"),
main_function_params_(main_function_params),
service_manager_thread_(std::move(service_manager_thread)) {}
main_function_params_(main_function_params) {}
void Init() override {
#if defined(OS_WIN)
......@@ -261,8 +257,7 @@ class CefUIThread : public base::Thread {
browser_runner_.reset(content::BrowserMainRunner::Create());
// Initialize browser process state. Uses the current thread's mesage loop.
int exit_code = browser_runner_->Initialize(
main_function_params_, std::move(service_manager_thread_));
int exit_code = browser_runner_->Initialize(main_function_params_);
CHECK_EQ(exit_code, -1);
}
......@@ -279,7 +274,6 @@ class CefUIThread : public base::Thread {
protected:
content::MainFunctionParams main_function_params_;
std::unique_ptr<content::BrowserProcessSubThread> service_manager_thread_;
std::unique_ptr<content::BrowserMainRunner> browser_runner_;
};
......@@ -441,30 +435,6 @@ bool CefMainDelegate::BasicStartupComplete(int* exit_code) {
switches::kUncaughtExceptionStackSize,
base::IntToString(settings.uncaught_exception_stack_size));
}
std::vector<std::string> disable_features;
if (settings.windowless_rendering_enabled) {
// Disable AsyncWheelEvents when OSR is enabled to avoid DCHECKs in
// MouseWheelEventQueue.
if (features::kAsyncWheelEvents.default_state ==
base::FEATURE_ENABLED_BY_DEFAULT) {
disable_features.push_back(features::kAsyncWheelEvents.name);
}
}
if (!disable_features.empty()) {
DCHECK(!base::FeatureList::GetInstance());
std::string disable_features_str =
command_line->GetSwitchValueASCII(switches::kDisableFeatures);
for (auto feature_str : disable_features) {
if (!disable_features_str.empty())
disable_features_str += ",";
disable_features_str += feature_str;
}
command_line->AppendSwitchASCII(switches::kDisableFeatures,
disable_features_str);
}
}
if (content_client_.application().get()) {
......@@ -576,13 +546,6 @@ void CefMainDelegate::SandboxInitialized(const std::string& process_type) {
int CefMainDelegate::RunProcess(
const std::string& process_type,
const content::MainFunctionParams& main_function_params) {
return RunProcess(process_type, main_function_params, nullptr);
}
int CefMainDelegate::RunProcess(
const std::string& process_type,
const content::MainFunctionParams& main_function_params,
std::unique_ptr<content::BrowserProcessSubThread> service_manager_thread) {
if (process_type.empty()) {
const CefSettings& settings = CefContext::Get()->settings();
if (!settings.multi_threaded_message_loop) {
......@@ -592,15 +555,13 @@ int CefMainDelegate::RunProcess(
// Initialize browser process state. Results in a call to
// CefBrowserMain::PreMainMessageLoopStart() which creates the UI message
// loop.
int exit_code = browser_runner_->Initialize(
main_function_params, std::move(service_manager_thread));
int exit_code = browser_runner_->Initialize(main_function_params);
if (exit_code >= 0)
return exit_code;
} else {
// Run the UI on a separate thread.
std::unique_ptr<base::Thread> thread;
thread.reset(new CefUIThread(main_function_params,
std::move(service_manager_thread)));
thread.reset(new CefUIThread(main_function_params));
base::Thread::Options options;
options.message_loop_type = base::MessageLoop::TYPE_UI;
if (!thread->StartWithOptions(options)) {
......
......@@ -38,10 +38,6 @@ class CefMainDelegate : public content::ContentMainDelegate {
int RunProcess(
const std::string& process_type,
const content::MainFunctionParams& main_function_params) override;
int RunProcess(const std::string& process_type,
const content::MainFunctionParams& main_function_params,
std::unique_ptr<content::BrowserProcessSubThread>
service_manager_thread) override;
void ProcessExiting(const std::string& process_type) override;
#if defined(OS_LINUX)
void ZygoteForked() override;
......
......@@ -49,7 +49,10 @@ patches = [
{
# Revert change on Windows that removes MessageLoop::os_modal_loop().
# https://codereview.chromium.org/1992243003
'name': 'message_loop_443_1992243003',
#
# Revert change that removes MessageLoopForUI constructor.
# https://chromium-review.googlesource.com/751322
'name': 'message_loop',
},
{
# Enable popups in offscreen rendering on OS X.
......@@ -371,11 +374,6 @@ patches = [
# https://bugs.chromium.org/p/chromium/issues/detail?id=729800#c48
'name': 'net_cookies_729800',
},
{
# Pass BrowserProcessSubThread to ContentMainDelegate::RunProcess.
# https://bitbucket.org/chromiumembedded/cef/issues/2456
'name': 'content_runprocess_2456',
},
{
# Linux: Use poll instead of select to fix crash during startup.
# https://bitbucket.org/chromiumembedded/cef/issues/2466
......
diff --git tools/clang/scripts/update.py tools/clang/scripts/update.py
index 226c3981a3bb..560a58070883 100755
index 03132fe9ba9b..aee7538e5902 100755
--- tools/clang/scripts/update.py
+++ tools/clang/scripts/update.py
@@ -392,7 +392,10 @@ def GetWinSDKDir():
......
diff --git content/browser/browser_plugin/browser_plugin_guest.cc content/browser/browser_plugin/browser_plugin_guest.cc
index 2cf5621ae33f..7a5d79ed09e4 100644
index f56ce93c3d5b..716cf8846378 100644
--- content/browser/browser_plugin/browser_plugin_guest.cc
+++ content/browser/browser_plugin/browser_plugin_guest.cc
@@ -312,8 +312,11 @@ void BrowserPluginGuest::InitInternal(
......@@ -37,10 +37,10 @@ index 2cf5621ae33f..7a5d79ed09e4 100644
attached_ = true;
diff --git content/browser/frame_host/interstitial_page_impl.cc content/browser/frame_host/interstitial_page_impl.cc
index ad9de41d1e3e..a87ec19a5f54 100644
index f839f62061bb..2150ceb6c780 100644
--- content/browser/frame_host/interstitial_page_impl.cc
+++ content/browser/frame_host/interstitial_page_impl.cc
@@ -622,7 +622,7 @@ WebContentsView* InterstitialPageImpl::CreateWebContentsView() {
@@ -619,7 +619,7 @@ WebContentsView* InterstitialPageImpl::CreateWebContentsView() {
WebContentsView* wcv =
static_cast<WebContentsImpl*>(web_contents())->GetView();
RenderWidgetHostViewBase* view =
......@@ -50,10 +50,10 @@ index ad9de41d1e3e..a87ec19a5f54 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 50047c045553..5e9424f62623 100644
index 41e44d5d658a..047c935d8ca2 100644
--- content/browser/web_contents/web_contents_view.h
+++ content/browser/web_contents/web_contents_view.h
@@ -25,7 +25,7 @@ struct ScreenInfo;
@@ -24,7 +24,7 @@ struct ScreenInfo;
// The WebContentsView is an interface that is implemented by the platform-
// dependent web contents views. The WebContents uses this interface to talk to
// them.
......@@ -62,7 +62,7 @@ index 50047c045553..5e9424f62623 100644
public:
virtual ~WebContentsView() {}
@@ -89,13 +89,9 @@ class WebContentsView {
@@ -88,13 +88,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,7 +79,7 @@ index 50047c045553..5e9424f62623 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 4a373e27bea4..684457680888 100644
index 713b17948ef7..8ec3e045783f 100644
--- content/browser/web_contents/web_contents_view_aura.cc
+++ content/browser/web_contents/web_contents_view_aura.cc
@@ -781,7 +781,8 @@ void WebContentsViewAura::CreateView(const gfx::Size& initial_size,
......@@ -101,7 +101,7 @@ index 4a373e27bea4..684457680888 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 96f23b81caf2..5fb786187b0c 100644
index 058f3e00d6f5..25a3ad4ec991 100644
--- content/browser/web_contents/web_contents_view_aura.h
+++ content/browser/web_contents/web_contents_view_aura.h
@@ -114,7 +114,7 @@ class CONTENT_EXPORT WebContentsViewAura
......@@ -114,7 +114,7 @@ index 96f23b81caf2..5fb786187b0c 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 345059d92363..39c376940df7 100644
index 688540cea253..8a143a74ce12 100644
--- content/browser/web_contents/web_contents_view_child_frame.cc
+++ content/browser/web_contents/web_contents_view_child_frame.cc
@@ -84,7 +84,7 @@ void WebContentsViewChildFrame::CreateView(const gfx::Size& initial_size,
......@@ -127,7 +127,7 @@ index 345059d92363..39c376940df7 100644
}
diff --git content/browser/web_contents/web_contents_view_child_frame.h content/browser/web_contents/web_contents_view_child_frame.h
index b5b3a22747ba..7a4e998d3e16 100644
index e5485f5609c3..589bbb400684 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,
......@@ -140,7 +140,7 @@ index b5b3a22747ba..7a4e998d3e16 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 2b272b7ff3de..cecd81826f7d 100644
index 44c68ed25b66..62026810703a 100644
--- content/browser/web_contents/web_contents_view_guest.cc
+++ content/browser/web_contents/web_contents_view_guest.cc
@@ -67,6 +67,8 @@ gfx::NativeWindow WebContentsViewGuest::GetTopLevelNativeWindow() const {
......@@ -195,7 +195,7 @@ index 2b272b7ff3de..cecd81826f7d 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 6f65cc816325..33a396e09671 100644
index 9e3511a9dabc..83dfee968d59 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,
......@@ -208,7 +208,7 @@ index 6f65cc816325..33a396e09671 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 15f03bafc0aa..c9418cbfa707 100644
index cf3305f96ddb..a44341905909 100644
--- content/browser/web_contents/web_contents_view_mac.h
+++ content/browser/web_contents/web_contents_view_mac.h
@@ -93,7 +93,7 @@ class WebContentsViewMac : public WebContentsView,
......@@ -221,10 +221,10 @@ index 15f03bafc0aa..c9418cbfa707 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 4da80f38595f..dfcf88e06b74 100644
index 082b74eff5b2..6f477ecba11e 100644
--- content/browser/web_contents/web_contents_view_mac.mm
+++ content/browser/web_contents/web_contents_view_mac.mm
@@ -348,7 +348,8 @@ void WebContentsViewMac::CreateView(
@@ -345,7 +345,8 @@ void WebContentsViewMac::CreateView(
}
RenderWidgetHostViewBase* WebContentsViewMac::CreateViewForWidget(
......@@ -234,7 +234,7 @@ index 4da80f38595f..dfcf88e06b74 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
@@ -360,6 +361,7 @@ RenderWidgetHostViewBase* WebContentsViewMac::CreateViewForWidget(
@@ -357,6 +358,7 @@ RenderWidgetHostViewBase* WebContentsViewMac::CreateViewForWidget(
render_widget_host->GetView());
}
......@@ -266,7 +266,7 @@ index d05dd5421458..fa13775f0512 100644
// a BrowserPlugin even when we are using cross process frames for guests. It
// should be removed after resolving https://crbug.com/642826).
diff --git extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
index 5adcb212aaaf..c899de6d9a80 100644
index a2a8e427b231..01d59c063d07 100644
--- extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
+++ extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
@@ -193,6 +193,8 @@ void MimeHandlerViewGuest::CreateWebContents(
......@@ -298,7 +298,7 @@ index 5adcb212aaaf..c899de6d9a80 100644
WebContents* source,
const content::OpenURLParams& params) {
diff --git extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h
index adcb0864ba28..f0ba4efc277a 100644
index 2a74abb320d5..16db064fb4a3 100644
--- extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h
+++ extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h
@@ -108,6 +108,10 @@ class MimeHandlerViewGuest :
......
diff --git chrome/browser/BUILD.gn chrome/browser/BUILD.gn
index 6de801443eac..f0d38f681077 100644
index a73a10627a5a..b6cf1c0b5608 100644
--- chrome/browser/BUILD.gn
+++ chrome/browser/BUILD.gn
@@ -8,6 +8,7 @@ import("//build/config/features.gni")
......@@ -10,7 +10,7 @@ index 6de801443eac..f0d38f681077 100644
import("//chrome/common/features.gni")
import("//components/feature_engagement/features.gni")
import("//components/feed/features.gni")
@@ -1644,6 +1645,7 @@ jumbo_split_static_library("browser") {
@@ -1646,6 +1647,7 @@ jumbo_split_static_library("browser") {
"//base:i18n",
"//base/allocator:buildflags",
"//cc",
......@@ -18,7 +18,7 @@ index 6de801443eac..f0d38f681077 100644
"//chrome:extra_resources",
"//chrome:resources",
"//chrome:strings",
@@ -1916,6 +1918,10 @@ jumbo_split_static_library("browser") {
@@ -1918,6 +1920,10 @@ jumbo_split_static_library("browser") {
]
}
......
diff --git chrome/renderer/BUILD.gn chrome/renderer/BUILD.gn
index 0b312fc03b93..929fca9eaee3 100644
index 0a1e5754bb7a..f21aa63a4b86 100644
--- chrome/renderer/BUILD.gn
+++ chrome/renderer/BUILD.gn
@@ -3,6 +3,7 @@
......@@ -10,7 +10,7 @@ index 0b312fc03b93..929fca9eaee3 100644
import("//chrome/common/features.gni")
import("//components/nacl/features.gni")
import("//components/offline_pages/buildflags/features.gni")
@@ -113,6 +114,7 @@ static_library("renderer") {
@@ -115,6 +116,7 @@ static_library("renderer") {
defines = []
deps = [
......@@ -18,7 +18,7 @@ index 0b312fc03b93..929fca9eaee3 100644
"//chrome:resources",
"//chrome:strings",
"//chrome/common",
@@ -176,6 +178,10 @@ static_library("renderer") {
@@ -178,6 +180,10 @@ static_library("renderer") {
configs += [ "//build/config/compiler:wexit_time_destructors" ]
......
diff --git content/app/content_service_manager_main_delegate.h content/app/content_service_manager_main_delegate.h
index 283e1daf6c33..548aa8e71b99 100644
index 6f32f97e3f92..66da6d5cec53 100644
--- content/app/content_service_manager_main_delegate.h
+++ content/app/content_service_manager_main_delegate.h
@@ -18,7 +18,8 @@ namespace content {
......
diff --git content/browser/compositor/gpu_process_transport_factory.cc content/browser/compositor/gpu_process_transport_factory.cc
index 03defa1ab778..73be8a2c8253 100644
index 20fa23379c4b..87d8ba911d53 100644
--- content/browser/compositor/gpu_process_transport_factory.cc
+++ content/browser/compositor/gpu_process_transport_factory.cc
@@ -494,10 +494,20 @@ void GpuProcessTransportFactory::EstablishedGpuChannel(
......
......@@ -94,7 +94,7 @@ index 201f23b9b422..4664c6b32c22 100644
"WillFailRequest state should come before WillProcessResponse");
return render_frame_host_;
diff --git content/browser/frame_host/render_frame_host_impl.cc content/browser/frame_host/render_frame_host_impl.cc
index 41f2205a0158..e4568812a8e7 100644
index 412fc31e185c..66ee1f2fbd86 100644
--- content/browser/frame_host/render_frame_host_impl.cc
+++ content/browser/frame_host/render_frame_host_impl.cc
@@ -1614,6 +1614,7 @@ void RenderFrameHostImpl::OnDidFailProvisionalLoadWithError(
......@@ -105,7 +105,19 @@ index 41f2205a0158..e4568812a8e7 100644
}
frame_tree_node_->navigator()->DidFailProvisionalLoadWithError(this, params);
@@ -4402,8 +4403,8 @@ void RenderFrameHostImpl::CreateNetworkServiceDefaultFactoryAndObserve(
@@ -3799,9 +3800,9 @@ void RenderFrameHostImpl::CommitNavigation(
// is used. Currently we have this here to make sure we have non-racy
// situation (https://crbug.com/849929).
DCHECK(base::FeatureList::IsEnabled(network::features::kNetworkService));
- auto* storage_partition = static_cast<StoragePartitionImpl*>(
+ auto* storage_partition =
BrowserContext::GetStoragePartition(
- GetSiteInstance()->GetBrowserContext(), GetSiteInstance()));
+ GetSiteInstance()->GetBrowserContext(), GetSiteInstance());
BrowserThread::PostTask(
BrowserThread::IO, FROM_HERE,
base::BindOnce(&PrefetchURLLoaderService::GetFactory,
@@ -4413,8 +4414,8 @@ void RenderFrameHostImpl::CreateNetworkServiceDefaultFactoryAndObserve(
RenderFrameDevToolsAgentHost::WillCreateURLLoaderFactory(
this, false /* is_navigation */, false /* is_download */,
&default_factory_request);
......@@ -116,17 +128,6 @@ index 41f2205a0158..e4568812a8e7 100644
if (g_create_network_factory_callback_for_test.Get().is_null()) {
storage_partition->GetNetworkContext()->CreateURLLoaderFactory(
std::move(default_factory_request), std::move(params));
@@ -4690,8 +4691,8 @@ void RenderFrameHostImpl::ConnectToPrefetchURLLoaderService(
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
DCHECK(base::FeatureList::IsEnabled(network::features::kNetworkService));
auto* storage_partition =
- static_cast<StoragePartitionImpl*>(BrowserContext::GetStoragePartition(
- GetSiteInstance()->GetBrowserContext(), GetSiteInstance()));
+ BrowserContext::GetStoragePartition(
+ GetSiteInstance()->GetBrowserContext(), GetSiteInstance());
auto subresource_factories = CloneSubresourceFactories();
// Temporary for https://crbug.com/849929.
CHECK(subresource_factories);
diff --git content/browser/frame_host/render_frame_message_filter.cc content/browser/frame_host/render_frame_message_filter.cc
index e39784552c5a..f9f520211e48 100644
--- content/browser/frame_host/render_frame_message_filter.cc
......@@ -284,10 +285,10 @@ index 3009401dac6b..b4c5a9e2db50 100644
};
diff --git content/common/frame_messages.h content/common/frame_messages.h
index 8284a4240b39..c883fa72292a 100644
index 94c3c6bfc0d4..ce424e1eaced 100644
--- content/common/frame_messages.h
+++ content/common/frame_messages.h
@@ -1382,9 +1382,10 @@ IPC_MESSAGE_ROUTED1(FrameHostMsg_PepperStopsPlayback,
@@ -1381,9 +1381,10 @@ IPC_MESSAGE_ROUTED1(FrameHostMsg_PepperStopsPlayback,
// type. If there is no matching plugin, |found| is false.
// |actual_mime_type| is the actual mime type supported by the
// found plugin.
......@@ -363,10 +364,10 @@ index 2f1f46075b27..94f300dfea5d 100644
virtual void FocusedNodeChanged(const blink::WebNode& node) {}
diff --git content/renderer/render_frame_impl.cc content/renderer/render_frame_impl.cc
index 2deec131e505..a77b188ed948 100644
index 39f42d884dff..e40852fe5b84 100644
--- content/renderer/render_frame_impl.cc
+++ content/renderer/render_frame_impl.cc
@@ -3449,7 +3449,8 @@ blink::WebPlugin* RenderFrameImpl::CreatePlugin(
@@ -3471,7 +3471,8 @@ blink::WebPlugin* RenderFrameImpl::CreatePlugin(
std::string mime_type;
bool found = false;
Send(new FrameHostMsg_GetPluginInfo(
......@@ -376,7 +377,7 @@ index 2deec131e505..a77b188ed948 100644
params.mime_type.Utf8(), &found, &info, &mime_type));
if (!found)
return nullptr;
@@ -3814,6 +3815,8 @@ void RenderFrameImpl::FrameDetached(DetachType type) {
@@ -3836,6 +3837,8 @@ void RenderFrameImpl::FrameDetached(DetachType type) {
void RenderFrameImpl::FrameFocused() {
Send(new FrameHostMsg_FrameFocused(routing_id_));
......@@ -386,7 +387,7 @@ index 2deec131e505..a77b188ed948 100644
void RenderFrameImpl::WillCommitProvisionalLoad() {
diff --git content/renderer/render_thread_impl.cc content/renderer/render_thread_impl.cc
index fc840f2bfbf8..53a7cd6962a8 100644
index ed9ecdafb96e..23e547afaedd 100644
--- content/renderer/render_thread_impl.cc
+++ content/renderer/render_thread_impl.cc
@@ -866,6 +866,8 @@ void RenderThreadImpl::Init(
......@@ -399,10 +400,10 @@ index fc840f2bfbf8..53a7cd6962a8 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 f06027e68086..4b720db48c3a 100644
index e586e93c934c..dcc761353829 100644
--- content/renderer/renderer_blink_platform_impl.cc
+++ content/renderer/renderer_blink_platform_impl.cc
@@ -1108,6 +1108,14 @@ void RendererBlinkPlatformImpl::RequestPurgeMemory() {
@@ -1123,6 +1123,14 @@ void RendererBlinkPlatformImpl::RequestPurgeMemory() {
base::MemoryCoordinatorClientRegistry::GetInstance()->PurgeMemory();
}
......@@ -418,10 +419,10 @@ index f06027e68086..4b720db48c3a 100644
if (!web_database_host_) {
web_database_host_ = blink::mojom::ThreadSafeWebDatabaseHostPtr::Create(
diff --git content/renderer/renderer_blink_platform_impl.h content/renderer/renderer_blink_platform_impl.h
index 464f3bb996e8..d1e15becf2a8 100644
index 11a3acd664b3..1167382c3bd1 100644
--- content/renderer/renderer_blink_platform_impl.h
+++ content/renderer/renderer_blink_platform_impl.h
@@ -230,6 +230,9 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
@@ -235,6 +235,9 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
mojo::ScopedDataPipeConsumerHandle handle) override;
void RequestPurgeMemory() override;
......
diff --git content/app/content_main_runner_impl.cc content/app/content_main_runner_impl.cc
index 1fec0c7876ca..0c8722204b0f 100644
--- content/app/content_main_runner_impl.cc
+++ content/app/content_main_runner_impl.cc
@@ -589,7 +589,8 @@ int RunBrowserProcessMain(
const MainFunctionParams& main_function_params,
ContentMainDelegate* delegate,
std::unique_ptr<BrowserProcessSubThread> service_manager_thread) {
- int exit_code = delegate->RunProcess("", main_function_params);
+ int exit_code = delegate->RunProcess("", main_function_params,
+ std::move(service_manager_thread));
#if defined(OS_ANDROID)
// In Android's browser process, the negative exit code doesn't mean the
// default behavior should be used as the UI message loop is managed by
diff --git content/browser/browser_main_runner_impl.h content/browser/browser_main_runner_impl.h
index adb084fe27c6..42a6fdc2d67f 100644
--- content/browser/browser_main_runner_impl.h
+++ content/browser/browser_main_runner_impl.h
@@ -42,7 +42,7 @@ class BrowserMainRunnerImpl : public BrowserMainRunner {
// on which ServiceManager is currently running.
int Initialize(
const MainFunctionParams& parameters,
- std::unique_ptr<BrowserProcessSubThread> service_manager_thread);
+ std::unique_ptr<BrowserProcessSubThread> service_manager_thread) override;
private:
// True if we have started to initialize the runner.
diff --git content/public/app/content_main_delegate.cc content/public/app/content_main_delegate.cc
index c4bdfd36ad0c..f6830c35fd1d 100644
--- content/public/app/content_main_delegate.cc
+++ content/public/app/content_main_delegate.cc
@@ -6,6 +6,7 @@
#include "base/logging.h"
#include "build/build_config.h"
+#include "content/browser/browser_process_sub_thread.h"
#include "content/public/gpu/content_gpu_client.h"
#include "content/public/renderer/content_renderer_client.h"
#include "content/public/utility/content_utility_client.h"
@@ -26,6 +27,13 @@ int ContentMainDelegate::RunProcess(
return -1;
}
+int ContentMainDelegate::RunProcess(
+ const std::string& process_type,
+ const MainFunctionParams& main_function_params,
+ std::unique_ptr<BrowserProcessSubThread> service_manager_thread) {
+ return RunProcess(process_type, main_function_params);
+}
+
ui::DataPack* ContentMainDelegate::LoadServiceManifestDataPack() {
return nullptr;
}
diff --git content/public/app/content_main_delegate.h content/public/app/content_main_delegate.h
index 979e25d1c1b9..87ef81c4e913 100644
--- content/public/app/content_main_delegate.h
+++ content/public/app/content_main_delegate.h
@@ -30,6 +30,7 @@ class DataPack;
namespace content {
+class BrowserProcessSubThread;
class ContentBrowserClient;
class ContentGpuClient;
class ContentRendererClient;
@@ -60,6 +61,12 @@ class CONTENT_EXPORT ContentMainDelegate {