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