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 353 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
364 | 364 |
365 WebKit::WebThemeEngine* TestWebKitPlatformSupport::themeEngine() { | 365 WebKit::WebThemeEngine* TestWebKitPlatformSupport::themeEngine() { |
366 return active_theme_engine_; | 366 return active_theme_engine_; |
367 } | 367 } |
368 #endif | 368 #endif |
369 | 369 |
370 WebKit::WebGraphicsContext3D* | 370 WebKit::WebGraphicsContext3D* |
371 TestWebKitPlatformSupport::createOffscreenGraphicsContext3D( | 371 TestWebKitPlatformSupport::createOffscreenGraphicsContext3D( |
372 const WebKit::WebGraphicsContext3D::Attributes& attributes) { | 372 const WebKit::WebGraphicsContext3D::Attributes& attributes) { |
373 using webkit::gpu::WebGraphicsContext3DInProcessCommandBufferImpl; | 373 using webkit::gpu::WebGraphicsContext3DInProcessCommandBufferImpl; |
374 return new WebGraphicsContext3DInProcessCommandBufferImpl(attributes); | 374 return WebGraphicsContext3DInProcessCommandBufferImpl::CreateOffscreenContext( |
| 375 attributes); |
375 } | 376 } |
376 | 377 |
377 WebKit::WebGraphicsContext3D* | 378 WebKit::WebGraphicsContext3D* |
378 TestWebKitPlatformSupport::sharedOffscreenGraphicsContext3D() { | 379 TestWebKitPlatformSupport::sharedOffscreenGraphicsContext3D() { |
379 main_thread_contexts_ = | 380 main_thread_contexts_ = |
380 webkit::gpu::TestContextProviderFactory::GetInstance()-> | 381 webkit::gpu::TestContextProviderFactory::GetInstance()-> |
381 OffscreenContextProviderForMainThread(); | 382 OffscreenContextProviderForMainThread(); |
382 if (!main_thread_contexts_) | 383 if (!main_thread_contexts_) |
383 return NULL; | 384 return NULL; |
384 return main_thread_contexts_->Context3d(); | 385 return main_thread_contexts_->Context3d(); |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
534 return view.release(); | 535 return view.release(); |
535 } | 536 } |
536 | 537 |
537 WebKit::WebLayerTreeView* | 538 WebKit::WebLayerTreeView* |
538 TestWebKitPlatformSupport::createLayerTreeViewForTesting( | 539 TestWebKitPlatformSupport::createLayerTreeViewForTesting( |
539 TestViewType type) { | 540 TestViewType type) { |
540 DCHECK_EQ(TestViewTypeUnitTest, type); | 541 DCHECK_EQ(TestViewTypeUnitTest, type); |
541 return createLayerTreeViewForTesting(); | 542 return createLayerTreeViewForTesting(); |
542 } | 543 } |
543 | 544 |
OLD | NEW |