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

Unified Diff: components/native_viewport/native_viewport_application_delegate.cc

Issue 1125423005: Do not create the NativeViewport PlatformEventSource when headless. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/native_viewport/native_viewport_application_delegate.cc
diff --git a/components/native_viewport/native_viewport_application_delegate.cc b/components/native_viewport/native_viewport_application_delegate.cc
index 63eff6bd5c512df3bb8563f4997f37c3fa737c45..f77a944efef1a27f5ab982c06ed2a89da28cdd65 100644
--- a/components/native_viewport/native_viewport_application_delegate.cc
+++ b/components/native_viewport/native_viewport_application_delegate.cc
@@ -24,12 +24,12 @@ NativeViewportApplicationDelegate::~NativeViewportApplicationDelegate() {
void NativeViewportApplicationDelegate::Initialize(
mojo::ApplicationImpl* application) {
- event_source_ = ui::PlatformEventSource::CreateDefault();
tracing_.Initialize(application);
base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
is_headless_ = command_line->HasSwitch(mojo::kUseHeadlessConfig);
if (!is_headless_) {
+ event_source_ = ui::PlatformEventSource::CreateDefault();
if (command_line->HasSwitch(mojo::kUseTestConfig))
gfx::GLSurface::InitializeOneOffForTests();
else
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698