| 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/debug/trace_event.h" | 9 #include "base/debug/trace_event.h" |
| 10 #include "base/file_util.h" | 10 #include "base/file_util.h" |
| (...skipping 736 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 747 TRACE_EVENT0("shutdown", "BrowserMainLoop::Subsystem:GPUProcessHostShim"); | 747 TRACE_EVENT0("shutdown", "BrowserMainLoop::Subsystem:GPUProcessHostShim"); |
| 748 GpuProcessHostUIShim::DestroyAll(); | 748 GpuProcessHostUIShim::DestroyAll(); |
| 749 } | 749 } |
| 750 // Cancel pending requests and prevent new requests. | 750 // Cancel pending requests and prevent new requests. |
| 751 if (resource_dispatcher_host_) { | 751 if (resource_dispatcher_host_) { |
| 752 TRACE_EVENT0("shutdown", | 752 TRACE_EVENT0("shutdown", |
| 753 "BrowserMainLoop::Subsystem:ResourceDispatcherHost"); | 753 "BrowserMainLoop::Subsystem:ResourceDispatcherHost"); |
| 754 resource_dispatcher_host_.get()->Shutdown(); | 754 resource_dispatcher_host_.get()->Shutdown(); |
| 755 } | 755 } |
| 756 | 756 |
| 757 #if defined(USE_AURA) | 757 #if defined(USE_AURA) || defined(OS_MACOSX) |
| 758 { | 758 if (ShouldInitializeBrowserGpuChannelAndTransportSurface()) { |
| 759 TRACE_EVENT0("shutdown", | 759 TRACE_EVENT0("shutdown", |
| 760 "BrowserMainLoop::Subsystem:ImageTransportFactory"); | 760 "BrowserMainLoop::Subsystem:ImageTransportFactory"); |
| 761 ImageTransportFactory::Terminate(); | 761 ImageTransportFactory::Terminate(); |
| 762 } | 762 } |
| 763 #endif | 763 #endif |
| 764 | 764 |
| 765 #if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) | 765 #if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) |
| 766 ZygoteHostImpl::GetInstance()->TearDownAfterLastChild(); | 766 ZygoteHostImpl::GetInstance()->TearDownAfterLastChild(); |
| 767 #endif // defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) | 767 #endif // defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) |
| 768 | 768 |
| (...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1130 base::TimeDelta::FromSeconds(delay_secs)); | 1130 base::TimeDelta::FromSeconds(delay_secs)); |
| 1131 } | 1131 } |
| 1132 | 1132 |
| 1133 void BrowserMainLoop::EndStartupTracing(const base::FilePath& trace_file) { | 1133 void BrowserMainLoop::EndStartupTracing(const base::FilePath& trace_file) { |
| 1134 is_tracing_startup_ = false; | 1134 is_tracing_startup_ = false; |
| 1135 TracingController::GetInstance()->DisableRecording( | 1135 TracingController::GetInstance()->DisableRecording( |
| 1136 trace_file, base::Bind(&OnStoppedStartupTracing)); | 1136 trace_file, base::Bind(&OnStoppedStartupTracing)); |
| 1137 } | 1137 } |
| 1138 | 1138 |
| 1139 } // namespace content | 1139 } // namespace content |
| OLD | NEW |