| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "build/build_config.h" | 5 #include "build/build_config.h" |
| 6 | 6 |
| 7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
| 8 #include <objbase.h> | 8 #include <objbase.h> |
| 9 #include <windows.h> | 9 #include <windows.h> |
| 10 #endif | 10 #endif |
| 11 | 11 |
| 12 #include "app/hi_res_timer_manager.h" | 12 #include "app/hi_res_timer_manager.h" |
| 13 #include "app/system_monitor.h" | 13 #include "app/system_monitor.h" |
| 14 #include "base/command_line.h" | 14 #include "base/command_line.h" |
| 15 #include "base/message_loop.h" | 15 #include "base/message_loop.h" |
| 16 #include "base/string_util.h" | 16 #include "base/string_util.h" |
| 17 #include "base/threading/platform_thread.h" |
| 17 #include "chrome/common/child_process.h" | 18 #include "chrome/common/child_process.h" |
| 18 #include "chrome/common/chrome_constants.h" | 19 #include "chrome/common/chrome_constants.h" |
| 19 #include "chrome/common/chrome_switches.h" | 20 #include "chrome/common/chrome_switches.h" |
| 20 #include "chrome/common/default_plugin.h" | 21 #include "chrome/common/default_plugin.h" |
| 21 #include "chrome/common/gpu_plugin.h" | 22 #include "chrome/common/gpu_plugin.h" |
| 22 #include "chrome/common/logging_chrome.h" | 23 #include "chrome/common/logging_chrome.h" |
| 23 #include "chrome/common/main_function_params.h" | 24 #include "chrome/common/main_function_params.h" |
| 24 #include "chrome/plugin/plugin_thread.h" | 25 #include "chrome/plugin/plugin_thread.h" |
| 25 | 26 |
| 26 #if defined(OS_WIN) | 27 #if defined(OS_WIN) |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 #endif | 85 #endif |
| 85 | 86 |
| 86 // The main thread of the plugin services UI. | 87 // The main thread of the plugin services UI. |
| 87 #if defined(OS_MACOSX) | 88 #if defined(OS_MACOSX) |
| 88 #if !defined(__LP64__) | 89 #if !defined(__LP64__) |
| 89 TrimInterposeEnvironment(); | 90 TrimInterposeEnvironment(); |
| 90 #endif | 91 #endif |
| 91 InitializeChromeApplication(); | 92 InitializeChromeApplication(); |
| 92 #endif | 93 #endif |
| 93 MessageLoop main_message_loop(MessageLoop::TYPE_UI); | 94 MessageLoop main_message_loop(MessageLoop::TYPE_UI); |
| 94 PlatformThread::SetName("CrPluginMain"); | 95 base::PlatformThread::SetName("CrPluginMain"); |
| 95 | 96 |
| 96 SystemMonitor system_monitor; | 97 SystemMonitor system_monitor; |
| 97 HighResolutionTimerManager high_resolution_timer_manager; | 98 HighResolutionTimerManager high_resolution_timer_manager; |
| 98 | 99 |
| 99 const CommandLine& parsed_command_line = parameters.command_line_; | 100 const CommandLine& parsed_command_line = parameters.command_line_; |
| 100 | 101 |
| 101 #if defined(OS_LINUX) | 102 #if defined(OS_LINUX) |
| 102 | 103 |
| 103 #if defined(ARCH_CPU_64_BITS) | 104 #if defined(ARCH_CPU_64_BITS) |
| 104 WorkaroundFlashLAHF(); | 105 WorkaroundFlashLAHF(); |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 | 170 |
| 170 MessageLoop::current()->Run(); | 171 MessageLoop::current()->Run(); |
| 171 } | 172 } |
| 172 | 173 |
| 173 #if defined(OS_WIN) | 174 #if defined(OS_WIN) |
| 174 CoUninitialize(); | 175 CoUninitialize(); |
| 175 #endif | 176 #endif |
| 176 | 177 |
| 177 return 0; | 178 return 0; |
| 178 } | 179 } |
| OLD | NEW |