Skip to content
Commit a5337aa0 authored by commit-queue@webkit.org's avatar commit-queue@webkit.org
Browse files

[chromium] Wire up scrollable sublayers in ScrollingCoordinatorChromium

https://bugs.webkit.org/show_bug.cgi?id=95679

Patch by Sami Kyostila <skyostil@chromium.org> on 2012-09-05
Reviewed by James Robinson.

Source/Platform:

Introduce WebLayerScrollClient for getting notified about scroll events targeting a WebLayer.

* Platform.gypi:
* chromium/public/WebLayer.h:
(WebKit):
(WebLayer):
* chromium/public/WebLayerScrollClient.h:

Source/WebCore:

Implement scrollable sublayers in ScrollingCoordinatorChromium and introduce a
WebLayerScrollClient which is notified of scroll events on its associated
scroll layer. GraphicsLayerChromium uses it to apply scroll events targeted to
its platform layer to a ScrollableArea, i.e., the RenderLayer corresponding to
the scrollable element.

Tests: GraphicsLayerChromiumTest.applyScrollToScrollableArea
       WebLayerTest.ScrollClient

* platform/graphics/chromium/GraphicsLayerChromium.cpp:
(WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
(WebCore::GraphicsLayerChromium::didScroll):
(WebCore):
* platform/graphics/chromium/GraphicsLayerChromium.h:
(WebCore):
(WebCore::GraphicsLayerChromium::setScrollableArea):
(WebCore::GraphicsLayerChromium::scrollableArea):
(GraphicsLayerChromium):
* platform/graphics/chromium/LayerChromium.cpp:
* platform/graphics/chromium/LayerChromium.h:
(WebKit):
(WebCore):
(WebCore::LayerChromium::setLayerScrollClient):
(LayerChromium):

Source/WebKit/chromium:

Introduce WebLayerScrollClient for getting notified about scroll events targeting a WebLayer.

* src/WebLayerImpl.cpp:
(WebKit::WebLayerImpl::setMaxScrollPosition):
(WebKit):
(WebKit::WebLayerImpl::setScrollClient):
(WebKit::WebLayerImpl::scrollBy):
* src/WebLayerImpl.h:
(WebLayerImpl):
* tests/CCLayerTreeHostTest.cpp:
* tests/GraphicsLayerChromiumTest.cpp:
(MockScrollableArea):
(WebKit):
(WebKit::TEST_F):
* tests/WebLayerTest.cpp:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127605 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent bb322ff5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment