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

Unified Diff: components/mus/mus_app.cc

Issue 2097533005: Set Chrome command buffer to be the default GPU command buffer (was mojo command buffer) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added #else 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
« no previous file with comments | « components/mus/common/switches.cc ('k') | components/mus/surfaces/surfaces_context_provider.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/mus/mus_app.cc
diff --git a/components/mus/mus_app.cc b/components/mus/mus_app.cc
index a42e6c572e3fb4b553b01c7e0774e292a5f90881..ff986bf67cf7f5d2c9277ed89b6089b64c283a78 100644
--- a/components/mus/mus_app.cc
+++ b/components/mus/mus_app.cc
@@ -79,7 +79,13 @@ struct MusApp::UserState {
MusApp::MusApp()
: test_config_(false),
+ // TODO(penghuang): Kludge: Use mojo command buffer when running on
+ // Windows since chrome command buffer breaks unit tests
+#if defined(OS_WIN)
use_chrome_gpu_command_buffer_(false),
+#else
+ use_chrome_gpu_command_buffer_(true),
+#endif
platform_screen_(ws::PlatformScreen::Create()),
weak_ptr_factory_(this) {}
@@ -145,9 +151,15 @@ void MusApp::Initialize(shell::Connector* connector,
test_config_ = base::CommandLine::ForCurrentProcess()->HasSwitch(
switches::kUseTestConfig);
+// TODO(penghuang): Kludge: use mojo command buffer when running on Windows
+// since Chrome command buffer breaks unit tests
+#if defined(OS_WIN)
+ use_chrome_gpu_command_buffer_ = false;
+#else
use_chrome_gpu_command_buffer_ =
- base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kUseChromeGpuCommandBufferInMus);
+ !base::CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kUseMojoGpuCommandBufferInMus);
+#endif
#if defined(USE_X11)
XInitThreads();
if (test_config_)
« no previous file with comments | « components/mus/common/switches.cc ('k') | components/mus/surfaces/surfaces_context_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698