Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(965)

Unified Diff: content/browser/browser_main_loop.cc

Issue 2197613003: gpu: Introduce GpuChannelEstablishFactory. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tot merge Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/browser/compositor/gpu_process_transport_factory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/browser_main_loop.cc
diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc
index 727d611473478b8de55cadb0774e7c253c34f894..71a74b0d82aeebe9eed0bd3f8a3589ace48e5910 100644
--- a/content/browser/browser_main_loop.cc
+++ b/content/browser/browser_main_loop.cc
@@ -1122,7 +1122,7 @@ void BrowserMainLoop::ShutdownThreadsAndCleanUp() {
}
// Must happen after the IO thread is shutdown since this may be accessed from
// it.
- if (!shell::ShellIsRemote()) {
+ {
TRACE_EVENT0("shutdown", "BrowserMainLoop::Subsystem:GPUChannelFactory");
if (BrowserGpuChannelHostFactory::instance())
BrowserGpuChannelHostFactory::Terminate();
@@ -1217,6 +1217,13 @@ int BrowserMainLoop::BrowserThreadsStarted() {
}
BrowserGpuChannelHostFactory::Initialize(established_gpu_channel);
ImageTransportFactory::Initialize();
+
+ gpu::GpuChannelEstablishFactory* factory =
+ GetContentClient()->browser()->GetGpuChannelEstablishFactory();
+ if (!factory)
+ factory = BrowserGpuChannelHostFactory::instance();
+ DCHECK(factory);
+ ImageTransportFactory::GetInstance()->SetGpuChannelEstablishFactory(factory);
#if defined(USE_AURA)
bool use_mus_in_renderer = base::CommandLine::ForCurrentProcess()->HasSwitch(
switches::kUseMusInRenderer);
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/browser/compositor/gpu_process_transport_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698