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/test/content_test_suite.h" | 5 #include "content/test/content_test_suite.h" |
6 | 6 |
7 #include "base/base_paths.h" | 7 #include "base/base_paths.h" |
8 #include "base/base_switches.h" | 8 #include "base/base_switches.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "build/build_config.h" | 11 #include "build/build_config.h" |
12 #include "content/public/common/content_client.h" | 12 #include "content/public/common/content_client.h" |
13 #include "content/public/common/content_paths.h" | 13 #include "content/public/common/content_paths.h" |
14 #include "content/public/test/test_content_client_initializer.h" | 14 #include "content/public/test/test_content_client_initializer.h" |
15 #include "gpu/config/gpu_util.h" | 15 #include "gpu/config/gpu_util.h" |
16 #include "testing/gtest/include/gtest/gtest.h" | 16 #include "testing/gtest/include/gtest/gtest.h" |
17 | 17 |
18 #if defined(OS_WIN) | 18 #if defined(OS_WIN) |
19 #include "ui/gfx/win/dpi.h" | 19 #include "ui/gfx/win/dpi.h" |
20 #endif | 20 #endif |
21 | 21 |
22 #if defined(OS_MACOSX) | 22 #if defined(OS_MACOSX) |
23 #include "base/mac/scoped_nsautorelease_pool.h" | 23 #include "base/mac/scoped_nsautorelease_pool.h" |
24 #if !defined(OS_IOS) | 24 #if !defined(OS_IOS) |
25 #include "base/test/mock_chrome_application_mac.h" | 25 #include "base/test/mock_chrome_application_mac.h" |
26 #include "content/browser/in_process_io_surface_manager_mac.h" | |
27 #endif | 26 #endif |
28 #endif | 27 #endif |
29 | 28 |
30 #if !defined(OS_IOS) | 29 #if !defined(OS_IOS) |
31 #include "base/base_switches.h" | 30 #include "base/base_switches.h" |
32 #include "base/command_line.h" | 31 #include "base/command_line.h" |
33 #include "media/base/media.h" | 32 #include "media/base/media.h" |
34 #include "ui/gl/test/gl_surface_test_support.h" | 33 #include "ui/gl/test/gl_surface_test_support.h" |
35 #endif | 34 #endif |
36 | 35 |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 gpu::ApplyGpuDriverBugWorkarounds(base::CommandLine::ForCurrentProcess()); | 103 gpu::ApplyGpuDriverBugWorkarounds(base::CommandLine::ForCurrentProcess()); |
105 } | 104 } |
106 #endif | 105 #endif |
107 testing::TestEventListeners& listeners = | 106 testing::TestEventListeners& listeners = |
108 testing::UnitTest::GetInstance()->listeners(); | 107 testing::UnitTest::GetInstance()->listeners(); |
109 listeners.Append(new TestInitializationListener); | 108 listeners.Append(new TestInitializationListener); |
110 #if defined(OS_ANDROID) | 109 #if defined(OS_ANDROID) |
111 SurfaceTextureManager::SetInstance( | 110 SurfaceTextureManager::SetInstance( |
112 InProcessSurfaceTextureManager::GetInstance()); | 111 InProcessSurfaceTextureManager::GetInstance()); |
113 #endif | 112 #endif |
114 #if defined(OS_MACOSX) && !defined(OS_IOS) | |
115 gfx::IOSurfaceManager::SetInstance(InProcessIOSurfaceManager::GetInstance()); | |
116 #endif | |
117 #if defined(USE_OZONE) | 113 #if defined(USE_OZONE) |
118 if (!is_child_process) { | 114 if (!is_child_process) { |
119 client_native_pixmap_factory_ = ui::ClientNativePixmapFactory::Create(); | 115 client_native_pixmap_factory_ = ui::ClientNativePixmapFactory::Create(); |
120 ui::ClientNativePixmapFactory::SetInstance( | 116 ui::ClientNativePixmapFactory::SetInstance( |
121 client_native_pixmap_factory_.get()); | 117 client_native_pixmap_factory_.get()); |
122 ui::ClientNativePixmapFactory::GetInstance()->Initialize( | 118 ui::ClientNativePixmapFactory::GetInstance()->Initialize( |
123 ui::OzonePlatform::GetInstance()->OpenClientNativePixmapDevice()); | 119 ui::OzonePlatform::GetInstance()->OpenClientNativePixmapDevice()); |
124 } | 120 } |
125 #endif | 121 #endif |
126 } | 122 } |
127 | 123 |
128 } // namespace content | 124 } // namespace content |
OLD | NEW |