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 "webkit/support/test_webkit_platform_support.h" | 5 #include "webkit/support/test_webkit_platform_support.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/file_util.h" | 8 #include "base/file_util.h" |
9 #include "base/files/scoped_temp_dir.h" | 9 #include "base/files/scoped_temp_dir.h" |
10 #include "base/metrics/stats_counters.h" | 10 #include "base/metrics/stats_counters.h" |
(...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
340 WebKit::WebThemeEngine* TestWebKitPlatformSupport::themeEngine() { | 340 WebKit::WebThemeEngine* TestWebKitPlatformSupport::themeEngine() { |
341 return active_theme_engine_; | 341 return active_theme_engine_; |
342 } | 342 } |
343 #endif | 343 #endif |
344 | 344 |
345 WebKit::WebGraphicsContext3D* | 345 WebKit::WebGraphicsContext3D* |
346 TestWebKitPlatformSupport::createOffscreenGraphicsContext3D( | 346 TestWebKitPlatformSupport::createOffscreenGraphicsContext3D( |
347 const WebKit::WebGraphicsContext3D::Attributes& attributes) { | 347 const WebKit::WebGraphicsContext3D::Attributes& attributes) { |
348 using webkit::gpu::WebGraphicsContext3DInProcessCommandBufferImpl; | 348 using webkit::gpu::WebGraphicsContext3DInProcessCommandBufferImpl; |
349 return WebGraphicsContext3DInProcessCommandBufferImpl::CreateOffscreenContext( | 349 return WebGraphicsContext3DInProcessCommandBufferImpl::CreateOffscreenContext( |
350 attributes); | 350 attributes).release(); |
351 } | 351 } |
352 | 352 |
353 WebKit::WebGraphicsContext3DProvider* TestWebKitPlatformSupport:: | 353 WebKit::WebGraphicsContext3DProvider* TestWebKitPlatformSupport:: |
354 createSharedOffscreenGraphicsContext3DProvider() { | 354 createSharedOffscreenGraphicsContext3DProvider() { |
355 main_thread_contexts_ = | 355 main_thread_contexts_ = |
356 webkit::gpu::TestContextProviderFactory::GetInstance()-> | 356 webkit::gpu::TestContextProviderFactory::GetInstance()-> |
357 OffscreenContextProviderForMainThread(); | 357 OffscreenContextProviderForMainThread(); |
358 if (!main_thread_contexts_.get()) | 358 if (!main_thread_contexts_.get()) |
359 return NULL; | 359 return NULL; |
360 return new webkit::gpu::WebGraphicsContext3DProviderImpl( | 360 return new webkit::gpu::WebGraphicsContext3DProviderImpl( |
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
506 return view.release(); | 506 return view.release(); |
507 } | 507 } |
508 | 508 |
509 WebKit::WebLayerTreeView* | 509 WebKit::WebLayerTreeView* |
510 TestWebKitPlatformSupport::createLayerTreeViewForTesting( | 510 TestWebKitPlatformSupport::createLayerTreeViewForTesting( |
511 TestViewType type) { | 511 TestViewType type) { |
512 DCHECK_EQ(TestViewTypeUnitTest, type); | 512 DCHECK_EQ(TestViewTypeUnitTest, type); |
513 return createLayerTreeViewForTesting(); | 513 return createLayerTreeViewForTesting(); |
514 } | 514 } |
515 | 515 |
OLD | NEW |