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

Unified Diff: content/renderer/render_thread_impl.cc

Issue 2087333002: mus::GpuService: Support establish GpuChannel asynchronously. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix a build error Created 4 years, 6 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
Index: content/renderer/render_thread_impl.cc
diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc
index 00cb65fd1c216131b234fe9320be1bd8a14efb07..0006eaa0579e35f1c9c595c1df2744726aa56bf8 100644
--- a/content/renderer/render_thread_impl.cc
+++ b/content/renderer/render_thread_impl.cc
@@ -199,6 +199,7 @@
#endif
#if defined(MOJO_SHELL_CLIENT)
+#include "components/mus/common/gpu_service.h"
#include "content/public/common/mojo_shell_connection.h"
#include "content/renderer/mus/render_widget_mus_connection.h"
#include "content/renderer/mus/render_widget_window_tree_client_factory.h"
@@ -1812,8 +1813,10 @@ RenderThreadImpl::CreateCompositorOutputSurface(
use_software = true;
#if defined(MOJO_SHELL_CLIENT)
- if (MojoShellConnection::GetForProcess() && !use_software &&
+ auto shell_connection = MojoShellConnection::GetForProcess();
+ if (shell_connection && !use_software &&
command_line.HasSwitch(switches::kUseMusInRenderer)) {
+ mus::GpuService::Initialize(shell_connection->GetConnector());
RenderWidgetMusConnection* connection =
RenderWidgetMusConnection::GetOrCreate(routing_id);
return connection->CreateOutputSurface();

Powered by Google App Engine
This is Rietveld 408576698