| 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 <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 138 #include "base/memory/memory_pressure_monitor_mac.h" | 138 #include "base/memory/memory_pressure_monitor_mac.h" |
| 139 #include "content/browser/bootstrap_sandbox_manager_mac.h" | 139 #include "content/browser/bootstrap_sandbox_manager_mac.h" |
| 140 #include "content/browser/cocoa/system_hotkey_helper_mac.h" | 140 #include "content/browser/cocoa/system_hotkey_helper_mac.h" |
| 141 #include "content/browser/mach_broker_mac.h" | 141 #include "content/browser/mach_broker_mac.h" |
| 142 #include "content/browser/renderer_host/browser_compositor_view_mac.h" | 142 #include "content/browser/renderer_host/browser_compositor_view_mac.h" |
| 143 #include "content/browser/theme_helper_mac.h" | 143 #include "content/browser/theme_helper_mac.h" |
| 144 #include "ui/accelerated_widget_mac/window_resize_helper_mac.h" | 144 #include "ui/accelerated_widget_mac/window_resize_helper_mac.h" |
| 145 #endif | 145 #endif |
| 146 | 146 |
| 147 #if defined(USE_OZONE) | 147 #if defined(USE_OZONE) |
| 148 #include "ui/ozone/public/client_native_pixmap_factory.h" | 148 #include "ui/ozone/public/client_native_pixmap_factory_ozone.h" |
| 149 #endif | 149 #endif |
| 150 | 150 |
| 151 #if defined(OS_WIN) | 151 #if defined(OS_WIN) |
| 152 #include <windows.h> | 152 #include <windows.h> |
| 153 #include <commctrl.h> | 153 #include <commctrl.h> |
| 154 #include <shellapi.h> | 154 #include <shellapi.h> |
| 155 | 155 |
| 156 #include "base/memory/memory_pressure_monitor_win.h" | 156 #include "base/memory/memory_pressure_monitor_win.h" |
| 157 #include "base/win/windows_version.h" | 157 #include "base/win/windows_version.h" |
| 158 #include "content/browser/screen_orientation/screen_orientation_delegate_win.h" | 158 #include "content/browser/screen_orientation/screen_orientation_delegate_win.h" |
| (...skipping 649 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 808 | 808 |
| 809 #if defined(OS_MACOSX) | 809 #if defined(OS_MACOSX) |
| 810 if (BootstrapSandboxManager::ShouldEnable()) { | 810 if (BootstrapSandboxManager::ShouldEnable()) { |
| 811 TRACE_EVENT0("startup", | 811 TRACE_EVENT0("startup", |
| 812 "BrowserMainLoop::Subsystem:BootstrapSandbox"); | 812 "BrowserMainLoop::Subsystem:BootstrapSandbox"); |
| 813 CHECK(BootstrapSandboxManager::GetInstance()); | 813 CHECK(BootstrapSandboxManager::GetInstance()); |
| 814 } | 814 } |
| 815 #endif | 815 #endif |
| 816 | 816 |
| 817 #if defined(USE_OZONE) | 817 #if defined(USE_OZONE) |
| 818 client_native_pixmap_factory_ = ui::ClientNativePixmapFactory::Create(); | 818 client_native_pixmap_factory_ = ui::CreateClientNativePixmapFactoryOzone(); |
| 819 ui::ClientNativePixmapFactory::SetInstance( | 819 ui::ClientNativePixmapFactory::SetInstance( |
| 820 client_native_pixmap_factory_.get()); | 820 client_native_pixmap_factory_.get()); |
| 821 #endif | 821 #endif |
| 822 | 822 |
| 823 if (parsed_command_line_.HasSwitch(switches::kMemoryMetrics)) { | 823 if (parsed_command_line_.HasSwitch(switches::kMemoryMetrics)) { |
| 824 TRACE_EVENT0("startup", "BrowserMainLoop::Subsystem:MemoryObserver"); | 824 TRACE_EVENT0("startup", "BrowserMainLoop::Subsystem:MemoryObserver"); |
| 825 memory_observer_.reset(new MemoryObserver()); | 825 memory_observer_.reset(new MemoryObserver()); |
| 826 base::MessageLoop::current()->AddTaskObserver(memory_observer_.get()); | 826 base::MessageLoop::current()->AddTaskObserver(memory_observer_.get()); |
| 827 } | 827 } |
| 828 | 828 |
| (...skipping 963 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1792 BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE), | 1792 BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE), |
| 1793 MediaInternals::GetInstance()); | 1793 MediaInternals::GetInstance()); |
| 1794 } | 1794 } |
| 1795 CHECK(audio_manager_); | 1795 CHECK(audio_manager_); |
| 1796 | 1796 |
| 1797 audio_system_ = media::AudioSystemImpl::Create(audio_manager_.get()); | 1797 audio_system_ = media::AudioSystemImpl::Create(audio_manager_.get()); |
| 1798 CHECK(audio_system_); | 1798 CHECK(audio_system_); |
| 1799 } | 1799 } |
| 1800 | 1800 |
| 1801 } // namespace content | 1801 } // namespace content |
| OLD | NEW |