| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/browser/browser_main_loop.h" | 5 #include "content/browser/browser_main_loop.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/location.h" | 9 #include "base/location.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 602 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 613 } else { | 613 } else { |
| 614 IOSurfaceManager::SetInstance(BrowserIOSurfaceManager::GetInstance()); | 614 IOSurfaceManager::SetInstance(BrowserIOSurfaceManager::GetInstance()); |
| 615 } | 615 } |
| 616 } | 616 } |
| 617 #endif | 617 #endif |
| 618 | 618 |
| 619 #if defined(USE_OZONE) | 619 #if defined(USE_OZONE) |
| 620 client_native_pixmap_factory_ = ui::ClientNativePixmapFactory::Create(); | 620 client_native_pixmap_factory_ = ui::ClientNativePixmapFactory::Create(); |
| 621 ui::ClientNativePixmapFactory::SetInstance( | 621 ui::ClientNativePixmapFactory::SetInstance( |
| 622 client_native_pixmap_factory_.get()); | 622 client_native_pixmap_factory_.get()); |
| 623 base::ScopedFD scoped_fd( |
| 624 ui::ClientNativePixmapFactory::GetInstance()->OpenVgemFD()); |
| 625 ui::ClientNativePixmapFactory::GetInstance()->SetVgemFD(&scoped_fd); |
| 623 #endif | 626 #endif |
| 624 | 627 |
| 625 if (parsed_command_line_.HasSwitch(switches::kMemoryMetrics)) { | 628 if (parsed_command_line_.HasSwitch(switches::kMemoryMetrics)) { |
| 626 TRACE_EVENT0("startup", "BrowserMainLoop::Subsystem:MemoryObserver"); | 629 TRACE_EVENT0("startup", "BrowserMainLoop::Subsystem:MemoryObserver"); |
| 627 memory_observer_.reset(new MemoryObserver()); | 630 memory_observer_.reset(new MemoryObserver()); |
| 628 base::MessageLoop::current()->AddTaskObserver(memory_observer_.get()); | 631 base::MessageLoop::current()->AddTaskObserver(memory_observer_.get()); |
| 629 } | 632 } |
| 630 | 633 |
| 631 if (parsed_command_line_.HasSwitch( | 634 if (parsed_command_line_.HasSwitch( |
| 632 switches::kEnableAggressiveDOMStorageFlushing)) { | 635 switches::kEnableAggressiveDOMStorageFlushing)) { |
| (...skipping 727 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1360 DCHECK(is_tracing_startup_); | 1363 DCHECK(is_tracing_startup_); |
| 1361 | 1364 |
| 1362 is_tracing_startup_ = false; | 1365 is_tracing_startup_ = false; |
| 1363 TracingController::GetInstance()->DisableRecording( | 1366 TracingController::GetInstance()->DisableRecording( |
| 1364 TracingController::CreateFileSink( | 1367 TracingController::CreateFileSink( |
| 1365 startup_trace_file_, | 1368 startup_trace_file_, |
| 1366 base::Bind(OnStoppedStartupTracing, startup_trace_file_))); | 1369 base::Bind(OnStoppedStartupTracing, startup_trace_file_))); |
| 1367 } | 1370 } |
| 1368 | 1371 |
| 1369 } // namespace content | 1372 } // namespace content |
| OLD | NEW |