Chromium Code Reviews| Index: components/view_manager/view_manager_app.cc |
| diff --git a/components/view_manager/view_manager_app.cc b/components/view_manager/view_manager_app.cc |
| index 1f9f283c6a88ae1539dff52c67b63607b0cf629c..2bce1a314c49011d6c430409238e1b7ffc210f83 100644 |
| --- a/components/view_manager/view_manager_app.cc |
| +++ b/components/view_manager/view_manager_app.cc |
| @@ -20,6 +20,10 @@ |
| #include "ui/events/platform/platform_event_source.h" |
| #include "ui/gl/gl_surface.h" |
| +#if defined(USE_X11) |
| +#include "ui/platform_window/x11/x11_window.h" |
| +#endif |
| + |
| using mojo::ApplicationConnection; |
| using mojo::ApplicationImpl; |
| using mojo::Gpu; |
| @@ -43,10 +47,16 @@ void ViewManagerApp::Initialize(ApplicationImpl* app) { |
| is_headless_ = command_line->HasSwitch(mojo::kUseHeadlessConfig); |
| if (!is_headless_) { |
| event_source_ = ui::PlatformEventSource::CreateDefault(); |
| - if (command_line->HasSwitch(mojo::kUseTestConfig)) |
| + bool test_config = command_line->HasSwitch(mojo::kUseTestConfig); |
| + if (test_config) |
| gfx::GLSurface::InitializeOneOffForTests(); |
| else |
| gfx::GLSurface::InitializeOneOff(); |
| + |
| +#if defined(USE_X11) |
| + if (test_config) |
| + ui::test::SetUseOverrideRedirectWindowByDefault(true); |
|
msw
2015/07/16 19:17:50
Should this be part of gfx::GLSurface::InitializeO
sadrul
2015/07/16 19:57:14
Hm, good point. Done.
|
| +#endif |
| } |
| #endif |