[chromium] Move check for threaded compositing from WebCompositorSupport to Platform
authorjamesr@google.com <jamesr@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Mar 2013 23:15:23 +0000 (23:15 +0000)
committerjamesr@google.com <jamesr@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Mar 2013 23:15:23 +0000 (23:15 +0000)
commit726d95ce67bbeb3959e5bcd9dae4d4238998b165
tree0e092514498b82260b1db030ead7db65e2282fae
parent7483018bcfc9a0ba2048e12954a2773f0bf917b3
[chromium] Move check for threaded compositing from WebCompositorSupport to Platform
https://bugs.webkit.org/show_bug.cgi?id=111386

Reviewed by Adrienne Walker.

Source/Platform:

This moves the query for if threaded compositing is enabled from WebCompositorSupport
to Platform. This is part of an effort to remove statefulness on WebCompositorSupport
and because it's much easier to override Platform functions for different tests.

* chromium/public/Platform.h:
(WebKit::Platform::isThreadedCompositingEnabled):
(Platform):
* chromium/public/WebCompositorSupport.h:

Source/WebCore:

This moves checks for whether threaded compositing is enabled from WebCompositorSupport
to Platform. In the case of Canvas2DLayerBridge, the check is moved completely out of
the class to make it easier for tests to specify the threaded configuration to use in the test.

* platform/graphics/chromium/Canvas2DLayerBridge.cpp:
(WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
* platform/graphics/chromium/Canvas2DLayerBridge.h:
(WebCore::Canvas2DLayerBridge::create):
(Canvas2DLayerBridge):
* platform/graphics/chromium/DrawingBufferChromium.cpp:
(WebCore::DrawingBuffer::DrawingBuffer):
* platform/graphics/skia/ImageBufferSkia.cpp:
(WebCore::createAcceleratedCanvas):

Source/WebKit/chromium:

* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::composite):
(WebKit::WebViewImpl::scheduleAnimation):
(WebKit::WebViewImpl::setIsAcceleratedCompositingActive):
(WebKit::WebViewImpl::scheduleComposite):
* tests/Canvas2DLayerBridgeTest.cpp:
(Canvas2DLayerBridgeTest::fullLifecycleTest):
* tests/Canvas2DLayerManagerTest.cpp:
(FakeCanvas2DLayerBridge::FakeCanvas2DLayerBridge):

Tools:

* DumpRenderTree/chromium/TestShell.cpp:
(TestShell::initialize):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@144827 268f45cc-cd09-0410-ab3c-d52691b4dbfc
14 files changed:
Source/Platform/ChangeLog
Source/Platform/chromium/public/Platform.h
Source/Platform/chromium/public/WebCompositorSupport.h
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/chromium/Canvas2DLayerBridge.cpp
Source/WebCore/platform/graphics/chromium/Canvas2DLayerBridge.h
Source/WebCore/platform/graphics/chromium/DrawingBufferChromium.cpp
Source/WebCore/platform/graphics/skia/ImageBufferSkia.cpp
Source/WebKit/chromium/ChangeLog
Source/WebKit/chromium/src/WebViewImpl.cpp
Source/WebKit/chromium/tests/Canvas2DLayerBridgeTest.cpp
Source/WebKit/chromium/tests/Canvas2DLayerManagerTest.cpp
Tools/ChangeLog
Tools/DumpRenderTree/chromium/TestShell.cpp