Changeset 161387 in webkit


Ignore:
Timestamp:
Jan 6, 2014 4:57:23 PM (10 years ago)
Author:
Simon Fraser
Message:

Hook up the RemoteScrollingCoordinator
https://bugs.webkit.org/show_bug.cgi?id=126547

Source/WebCore:

Reviewed by Tim Horton.

Export lots of scrolling-related symbols for use by WebKit2.

  • WebCore.exp.in:

Source/WebKit2:

Reviewed by Tim Horton.

Hook up the RemoteScrollingCoordinator in WebKit2.

When the RemoteLayerTreeDrawingArea is in use, WebPageProxy creates
a RemoteScrollingCoordinator, and hands it mouseWheel events. It then
scrolls via a RemoteScrollingTree constructed from state tree commits from the
WebProcess.

Scrolling tree commits happen via a transaction received by RemoteLayerTreeDrawingAreaProxy,
atomically with layer tree transactions.

  • Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:

(WebKit::RemoteScrollingCoordinatorTransaction::encode): Fix encoding for some
cases seen in WebKitTestRunner where a page has no ScrollingCoordinator.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::initializeWebPage): Create the RemoteScrollingCoordinatorProxy
when using a remote layer tree drawing area.
(WebKit::WebPageProxy::handleWheelEvent): Pass to the scrolling coordinator.

  • UIProcess/WebPageProxy.h:

(WebKit::WebPageProxy::scrollingCoordinatorProxy):

  • UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h: Include the RemoteScrollingCoordinatorTransaction.
  • UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.messages.in:
  • UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:

(WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree):

  • UIProcess/mac/RemoteLayerTreeHost.mm:

(WebKit::RemoteLayerTreeHost::getLayer): It's valid to get a 0 layerID (e.g. when
a layer disappears) so handle this case.

  • WebKit2.xcodeproj/project.pbxproj:
  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::WebChromeClient::createScrollingCoordinator): Override to create the
RemoteScrollingCoordinator in the WebProcess.

  • WebProcess/WebCoreSupport/WebChromeClient.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::scrollingCoordinator): Not inline to avoid polluting the
header with #includes.

  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h: Say that we want a ScrollingCoordinator.
  • WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:

(WebKit::RemoteLayerTreeDrawingArea::flushLayers): Add the scrollingTransaction to the
message.

Location:
trunk/Source
Files:
17 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r161385 r161387  
     12014-01-06  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Hook up the RemoteScrollingCoordinator
     4        https://bugs.webkit.org/show_bug.cgi?id=126547
     5
     6        Reviewed by Tim Horton.
     7
     8        Export lots of scrolling-related symbols for use by WebKit2.
     9
     10        * WebCore.exp.in:
     11
    1122014-01-06  Seokju Kwon  <seokju@webkit.org>
    213
  • trunk/Source/WebCore/WebCore.exp.in

    r161338 r161387  
    10021002__ZN7WebCore4Page32setMemoryCacheClientCallsEnabledEb
    10031003__ZN7WebCore4Page35resumeActiveDOMObjectsAndAnimationsEv
     1004__ZN7WebCore4Page20scrollingCoordinatorEv
    10041005__ZN7WebCore4Page36setShouldSuppressScrollbarAnimationsEb
    10051006__ZN7WebCore4Page36suspendActiveDOMObjectsAndAnimationsEv
     
    28642865
    28652866#if ENABLE(ASYNC_SCROLLING)
     2867__ZN7WebCore13ScrollingTree16handleWheelEventERKNS_18PlatformWheelEventE
     2868__ZN7WebCore13ScrollingTree18commitNewTreeStateEN3WTF10PassOwnPtrINS_18ScrollingStateTreeEEE
    28662869__ZN7WebCore13ScrollingTree21setCanRubberBandStateEbbbb
     2870__ZN7WebCore13ScrollingTree31willWheelEventStartSwipeGestureERKNS_18PlatformWheelEventE
     2871__ZN7WebCore13ScrollingTree35shouldHandleWheelEventSynchronouslyERKNS_18PlatformWheelEventE
    28672872__ZN7WebCore13ScrollingTree37setScrollingPerformanceLoggingEnabledEb
     2873__ZN7WebCore13ScrollingTreeC2Ev
    28682874__ZN7WebCore13ScrollingTreeD1Ev
     2875__ZN7WebCore13ScrollingTreeD2Ev
    28692876__ZN7WebCore15ScrollingThread15dispatchBarrierERKN3WTF8FunctionIFvvEEE
    28702877__ZN7WebCore15ScrollingThread8dispatchERKN3WTF8FunctionIFvvEEE
     2878__ZN7WebCore18ScrollingStateNode8setLayerERKNS_19LayerRepresentationE
     2879__ZN7WebCore18ScrollingStateTree10attachNodeENS_17ScrollingNodeTypeEyy
     2880__ZN7WebCore18ScrollingStateTree14stateNodeForIDEy
     2881__ZN7WebCore18ScrollingStateTree15setRemovedNodesEN3WTF6VectorIyLm0ENS1_15CrashOnOverflowEEE
     2882__ZN7WebCore18ScrollingStateTree6commitENS_19LayerRepresentation4TypeE
     2883__ZN7WebCore18ScrollingStateTree6createEPNS_25AsyncScrollingCoordinatorE
     2884__ZN7WebCore18ScrollingStateTreeD1Ev
     2885__ZN7WebCore20ScrollingCoordinator13pageDestroyedEv
    28712886__ZN7WebCore20ScrollingCoordinator45setForceSynchronousScrollLayerPositionUpdatesEb
    2872 __ZN7WebCore4Page20scrollingCoordinatorEv
     2887__ZN7WebCore22ScrollingTreeFixedNode6createERNS_13ScrollingTreeEy
     2888__ZN7WebCore23ScrollingStateFixedNode17updateConstraintsERKNS_32FixedPositionViewportConstraintsE
     2889__ZN7WebCore23ScrollingTreeStickyNode6createERNS_13ScrollingTreeEy
     2890__ZN7WebCore24ScrollingStateStickyNode17updateConstraintsERKNS_33StickyPositionViewportConstraintsE
     2891__ZN7WebCore20ScrollingCoordinator35scheduleUpdateScrollPositionForNodeEyRKNS_8IntPointEbNS_31SetOrSyncScrollingLayerPositionE
     2892__ZN7WebCore25AsyncScrollingCoordinator14clearStateTreeEv
     2893__ZN7WebCore25AsyncScrollingCoordinator17attachToStateTreeENS_17ScrollingNodeTypeEyy
     2894__ZN7WebCore25AsyncScrollingCoordinator18syncChildPositionsERKNS_10LayoutRectE
     2895__ZN7WebCore25AsyncScrollingCoordinator19detachFromStateTreeEy
     2896__ZN7WebCore25AsyncScrollingCoordinator19updateScrollingNodeEyPNS_13GraphicsLayerES2_
     2897__ZN7WebCore25AsyncScrollingCoordinator22frameViewLayoutUpdatedEPNS_9FrameViewE
     2898__ZNK7WebCore25AsyncScrollingCoordinator24scrollingStateTreeAsTextEv
     2899__ZN7WebCore25AsyncScrollingCoordinator27frameViewRootLayerDidChangeEPNS_9FrameViewE
     2900__ZN7WebCore25AsyncScrollingCoordinator27requestScrollPositionUpdateEPNS_9FrameViewERKNS_8IntPointE
     2901__ZN7WebCore25AsyncScrollingCoordinator29updateViewportConstrainedNodeEyRKNS_19ViewportConstraintsEPNS_13GraphicsLayerE
     2902__ZN7WebCore25AsyncScrollingCoordinator30setSynchronousScrollingReasonsEj
     2903__ZN7WebCore25AsyncScrollingCoordinator37scrollableAreaScrollbarLayerDidChangeEPNS_14ScrollableAreaENS_20ScrollbarOrientationE
     2904__ZN7WebCore25AsyncScrollingCoordinator43recomputeWheelEventHandlerCountForFrameViewEPNS_9FrameViewE
     2905__ZN7WebCore25AsyncScrollingCoordinatorC2EPNS_4PageE
     2906__ZN7WebCore25AsyncScrollingCoordinatorD2Ev
     2907__ZN7WebCore27ScrollingStateScrollingNode14setFooterLayerERKNS_19LayerRepresentationE
     2908__ZN7WebCore27ScrollingStateScrollingNode14setHeaderLayerERKNS_19LayerRepresentationE
     2909__ZN7WebCore27ScrollingStateScrollingNode15setFooterHeightEi
     2910__ZN7WebCore27ScrollingStateScrollingNode15setHeaderHeightEi
     2911__ZN7WebCore27ScrollingStateScrollingNode15setScrollOriginERKNS_8IntPointE
     2912__ZN7WebCore27ScrollingStateScrollingNode15setViewportRectERKNS_7IntRectE
     2913__ZN7WebCore27ScrollingStateScrollingNode19setFrameScaleFactorEf
     2914__ZN7WebCore27ScrollingStateScrollingNode20setTotalContentsSizeERKNS_7IntSizeE
     2915__ZN7WebCore27ScrollingStateScrollingNode24setCounterScrollingLayerERKNS_19LayerRepresentationE
     2916__ZN7WebCore27ScrollingStateScrollingNode25setWheelEventHandlerCountEj
     2917__ZN7WebCore27ScrollingStateScrollingNode27setScrollableAreaParametersERKNS_24ScrollableAreaParametersE
     2918__ZN7WebCore27ScrollingStateScrollingNode30setSynchronousScrollingReasonsEj
     2919__ZN7WebCore27ScrollingStateScrollingNode33setScrollBehaviorForFixedElementsENS_30ScrollBehaviorForFixedElementsE
     2920__ZN7WebCore29ScrollingTreeScrollingNodeMac6createERNS_13ScrollingTreeEy
    28732921#endif
    28742922
  • trunk/Source/WebKit2/ChangeLog

    r161386 r161387  
     12014-01-06  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Hook up the RemoteScrollingCoordinator
     4        https://bugs.webkit.org/show_bug.cgi?id=126547
     5
     6        Reviewed by Tim Horton.
     7       
     8        Hook up the RemoteScrollingCoordinator in WebKit2.
     9       
     10        When the RemoteLayerTreeDrawingArea is in use, WebPageProxy creates
     11        a RemoteScrollingCoordinator, and hands it mouseWheel events. It then
     12        scrolls via a RemoteScrollingTree constructed from state tree commits from the
     13        WebProcess.
     14       
     15        Scrolling tree commits happen via a transaction received by RemoteLayerTreeDrawingAreaProxy,
     16        atomically with layer tree transactions.
     17
     18        * Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
     19        (WebKit::RemoteScrollingCoordinatorTransaction::encode): Fix encoding for some
     20        cases seen in WebKitTestRunner where a page has no ScrollingCoordinator.
     21        * UIProcess/WebPageProxy.cpp:
     22        (WebKit::WebPageProxy::initializeWebPage): Create the RemoteScrollingCoordinatorProxy
     23        when using a remote layer tree drawing area.
     24        (WebKit::WebPageProxy::handleWheelEvent): Pass to the scrolling coordinator.
     25        * UIProcess/WebPageProxy.h:
     26        (WebKit::WebPageProxy::scrollingCoordinatorProxy):
     27        * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h: Include the RemoteScrollingCoordinatorTransaction.
     28        * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.messages.in:
     29        * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
     30        (WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree):
     31        * UIProcess/mac/RemoteLayerTreeHost.mm:
     32        (WebKit::RemoteLayerTreeHost::getLayer): It's valid to get a 0 layerID (e.g. when
     33        a layer disappears) so handle this case.
     34        * WebKit2.xcodeproj/project.pbxproj:
     35        * WebProcess/WebCoreSupport/WebChromeClient.cpp:
     36        (WebKit::WebChromeClient::createScrollingCoordinator): Override to create the
     37        RemoteScrollingCoordinator in the WebProcess.
     38        * WebProcess/WebCoreSupport/WebChromeClient.h:
     39        * WebProcess/WebPage/WebPage.cpp:
     40        (WebKit::WebPage::scrollingCoordinator): Not inline to avoid polluting the
     41        header with #includes.
     42        * WebProcess/WebPage/WebPage.h:
     43        * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h: Say that we want a ScrollingCoordinator.
     44        * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
     45        (WebKit::RemoteLayerTreeDrawingArea::flushLayers): Add the scrollingTransaction to the
     46        message.
     47
    1482014-01-06  Jaehun Lim  <ljaehun.lim@samsung.com>
    249
  • trunk/Source/WebKit2/Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp

    r161373 r161387  
    231231void RemoteScrollingCoordinatorTransaction::encode(IPC::ArgumentEncoder& encoder) const
    232232{
    233     encoder << m_scrollingStateTree->nodeCount();
    234    
    235     if (const ScrollingStateNode* rootNode = m_scrollingStateTree->rootStateNode())
    236         encodeNodeAndDescendants(encoder, *rootNode);
    237    
    238     encoder << m_scrollingStateTree->removedNodes();
     233    int numNodes = m_scrollingStateTree ? m_scrollingStateTree->nodeCount() : 0;
     234    encoder << numNodes;
     235
     236    if (m_scrollingStateTree) {
     237        if (const ScrollingStateNode* rootNode = m_scrollingStateTree->rootStateNode())
     238            encodeNodeAndDescendants(encoder, *rootNode);
     239
     240        encoder << m_scrollingStateTree->removedNodes();
     241    } else
     242        encoder << Vector<ScrollingNodeID>();
    239243}
    240244
  • trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp

    r161358 r161387  
    6262#include "WebEditCommandProxy.h"
    6363#include "WebEvent.h"
     64#include "WebEventConversion.h"
    6465#include "WebFormSubmissionListenerProxy.h"
    6566#include "WebFramePolicyListenerProxy.h"
     
    9394#include <wtf/NeverDestroyed.h>
    9495#include <stdio.h>
     96
     97#if ENABLE(ASYNC_SCROLLING)
     98#include "RemoteScrollingCoordinatorProxy.h"
     99#endif
    95100
    96101#if USE(COORDINATED_GRAPHICS)
     
    508513    ASSERT(m_drawingArea);
    509514
     515#if ENABLE(ASYNC_SCROLLING)
     516    if (m_drawingArea->type() == DrawingAreaTypeRemoteLayerTree)
     517        m_scrollingCoordinatorProxy = std::make_unique<RemoteScrollingCoordinatorProxy>(*this);
     518#endif
     519
    510520#if ENABLE(INSPECTOR_SERVER)
    511521    if (pageGroup().preferences()->developerExtrasEnabled())
     
    12361246void WebPageProxy::handleWheelEvent(const NativeWebWheelEvent& event)
    12371247{
     1248#if ENABLE(ASYNC_SCROLLING)
     1249    if (m_scrollingCoordinatorProxy && m_scrollingCoordinatorProxy->handleWheelEvent(platform(event)))
     1250        return;
     1251#endif
     1252
    12381253    if (!isValid())
    12391254        return;
  • trunk/Source/WebKit2/UIProcess/WebPageProxy.h

    r161358 r161387  
    137137class NativeWebWheelEvent;
    138138class PageClient;
     139class RemoteScrollingCoordinatorProxy;
    139140class StringPairVector;
    140141class WebBackForwardList;
     
    336337
    337338    DrawingAreaProxy* drawingArea() const { return m_drawingArea.get(); }
     339   
     340    RemoteScrollingCoordinatorProxy* scrollingCoordinatorProxy() const { return m_scrollingCoordinatorProxy.get(); }
    338341
    339342    WebBackForwardList& backForwardList() { return m_backForwardList.get(); }
     
    11701173
    11711174    std::unique_ptr<DrawingAreaProxy> m_drawingArea;
     1175    std::unique_ptr<RemoteScrollingCoordinatorProxy> m_scrollingCoordinatorProxy;
     1176
    11721177    Ref<WebProcessProxy> m_process;
    11731178    Ref<WebPageGroup> m_pageGroup;
  • trunk/Source/WebKit2/UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h

    r161373 r161387  
    3535
    3636class RemoteLayerTreeTransaction;
     37class RemoteScrollingCoordinatorTransaction;
    3738
    3839class RemoteLayerTreeDrawingAreaProxy : public DrawingAreaProxy {
     
    5253
    5354    // Message handlers
    54     void commitLayerTree(const RemoteLayerTreeTransaction&);
     55    void commitLayerTree(const RemoteLayerTreeTransaction&, const RemoteScrollingCoordinatorTransaction&);
    5556   
    5657    void sendUpdateGeometry();
  • trunk/Source/WebKit2/UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.messages.in

    r161327 r161387  
    2222
    2323messages -> RemoteLayerTreeDrawingAreaProxy {
    24     void CommitLayerTree(WebKit::RemoteLayerTreeTransaction layerTreeTransaction)
     24    void CommitLayerTree(WebKit::RemoteLayerTreeTransaction layerTreeTransaction, WebKit::RemoteScrollingCoordinatorTransaction scrollingTreeTransaction)
    2525}
  • trunk/Source/WebKit2/UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm

    r161327 r161387  
    2929#import "RemoteLayerTreeDrawingAreaProxyMessages.h"
    3030#import "DrawingAreaMessages.h"
     31#import "RemoteScrollingCoordinatorProxy.h"
    3132#import "WebPageProxy.h"
    3233#import "WebProcessProxy.h"
     
    8384}
    8485
    85 void RemoteLayerTreeDrawingAreaProxy::commitLayerTree(const RemoteLayerTreeTransaction& layerTreeTransaction)
     86void RemoteLayerTreeDrawingAreaProxy::commitLayerTree(const RemoteLayerTreeTransaction& layerTreeTransaction, const RemoteScrollingCoordinatorTransaction& scrollingTreeTransaction)
    8687{
    8788    m_remoteLayerTreeHost.updateLayerTree(layerTreeTransaction);
     89    m_webPageProxy->scrollingCoordinatorProxy()->updateScrollingTree(scrollingTreeTransaction);
    8890}
    8991
  • trunk/Source/WebKit2/UIProcess/mac/RemoteLayerTreeHost.mm

    r161327 r161387  
    9090CALayer *RemoteLayerTreeHost::getLayer(GraphicsLayer::PlatformLayerID layerID) const
    9191{
     92    if (!layerID)
     93        return nil;
     94
    9295    return m_layers.get(layerID).get();
    9396}
  • trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj

    r161373 r161387  
    5858                0F5947A3187B3B7D00437857 /* RemoteScrollingCoordinatorTransaction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0F5947A1187B3B7D00437857 /* RemoteScrollingCoordinatorTransaction.cpp */; };
    5959                0F5947A4187B3B7D00437857 /* RemoteScrollingCoordinatorTransaction.h in Headers */ = {isa = PBXBuildFile; fileRef = 0F5947A2187B3B7D00437857 /* RemoteScrollingCoordinatorTransaction.h */; };
     60                0F5947A7187B517600437857 /* RemoteScrollingCoordinatorMessageReceiver.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0F5947A5187B517600437857 /* RemoteScrollingCoordinatorMessageReceiver.cpp */; };
     61                0F5947A8187B517600437857 /* RemoteScrollingCoordinatorMessages.h in Headers */ = {isa = PBXBuildFile; fileRef = 0F5947A6187B517600437857 /* RemoteScrollingCoordinatorMessages.h */; };
    6062                0FB659231208B4DB0044816C /* DrawingAreaInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = 0FB659221208B4DB0044816C /* DrawingAreaInfo.h */; };
    6163                0FF24A2D1879E4BC003ABF0C /* RemoteLayerTreeDrawingAreaProxyMessageReceiver.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0FF24A2B1879E4BC003ABF0C /* RemoteLayerTreeDrawingAreaProxyMessageReceiver.cpp */; };
     
    16041606                0F5947A1187B3B7D00437857 /* RemoteScrollingCoordinatorTransaction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RemoteScrollingCoordinatorTransaction.cpp; path = Scrolling/RemoteScrollingCoordinatorTransaction.cpp; sourceTree = "<group>"; };
    16051607                0F5947A2187B3B7D00437857 /* RemoteScrollingCoordinatorTransaction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RemoteScrollingCoordinatorTransaction.h; path = Scrolling/RemoteScrollingCoordinatorTransaction.h; sourceTree = "<group>"; };
     1608                0F5947A5187B517600437857 /* RemoteScrollingCoordinatorMessageReceiver.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RemoteScrollingCoordinatorMessageReceiver.cpp; path = RemoteScrollingCoordinatorMessageReceiver.cpp; sourceTree = "<group>"; };
     1609                0F5947A6187B517600437857 /* RemoteScrollingCoordinatorMessages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RemoteScrollingCoordinatorMessages.h; path = RemoteScrollingCoordinatorMessages.h; sourceTree = "<group>"; };
    16061610                0FB659221208B4DB0044816C /* DrawingAreaInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DrawingAreaInfo.h; sourceTree = "<group>"; };
    16071611                0FF24A2B1879E4BC003ABF0C /* RemoteLayerTreeDrawingAreaProxyMessageReceiver.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RemoteLayerTreeDrawingAreaProxyMessageReceiver.cpp; sourceTree = "<group>"; };
     
    55955599                                0FF24A2B1879E4BC003ABF0C /* RemoteLayerTreeDrawingAreaProxyMessageReceiver.cpp */,
    55965600                                0FF24A2C1879E4BC003ABF0C /* RemoteLayerTreeDrawingAreaProxyMessages.h */,
     5601                                0F5947A5187B517600437857 /* RemoteScrollingCoordinatorMessageReceiver.cpp */,
     5602                                0F5947A6187B517600437857 /* RemoteScrollingCoordinatorMessages.h */,
    55975603                                E18E6911169B667B009B6670 /* SecItemShimMessageReceiver.cpp */,
    55985604                                E18E6912169B667B009B6670 /* SecItemShimMessages.h */,
     
    61086114                                BCA0EF9F12332642007D3CFB /* WebEditCommandProxy.h in Headers */,
    61096115                                BC032D7D10F4378D0058C15A /* WebEditorClient.h in Headers */,
     6116                                0F5947A8187B517600437857 /* RemoteScrollingCoordinatorMessages.h in Headers */,
    61106117                                516A4A5D120A2CCD00C05B7F /* APIError.h in Headers */,
    61116118                                1A433F0D113C53DD00FACDE9 /* WebErrors.h in Headers */,
     
    75987605                                378E1A3D181ED6FF0031007A /* APIObject.mm in Sources */,
    75997606                                51FB08FF1639DE1A00EC324A /* WebResourceLoadScheduler.cpp in Sources */,
     7607                                0F5947A7187B517600437857 /* RemoteScrollingCoordinatorMessageReceiver.cpp in Sources */,
    76007608                                D3B9484811FF4B6500032B39 /* WebSearchPopupMenu.cpp in Sources */,
    76017609                                BCC5715C115ADAEF001CCAF9 /* WebSystemInterface.mm in Sources */,
  • trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp

    r161152 r161387  
    3333#include "LayerTreeHost.h"
    3434#include "PageBanner.h"
     35#include "RemoteScrollingCoordinator.h"
    3536#include "WebColorChooser.h"
    3637#include "WebCoreArgumentCoders.h"
     
    799800#endif
    800801
     802PassRefPtr<ScrollingCoordinator> WebChromeClient::createScrollingCoordinator(Page* page) const
     803{
     804    ASSERT(m_page->corePage() == page);
     805    if (m_page->drawingArea()->type() == DrawingAreaTypeRemoteLayerTree)
     806        return RemoteScrollingCoordinator::create(m_page);
     807
     808    return 0;
     809}
     810
    801811#if ENABLE(TOUCH_EVENTS)
    802812void WebChromeClient::needTouchEvents(bool needTouchEvents)
  • trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h

    r161106 r161387  
    228228#endif
    229229
     230    virtual PassRefPtr<WebCore::ScrollingCoordinator> createScrollingCoordinator(WebCore::Page*) const OVERRIDE;
     231
    230232#if ENABLE(TOUCH_EVENTS)
    231233    virtual void needTouchEvents(bool) OVERRIDE;
  • trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp

    r161367 r161387  
    31523152}
    31533153
     3154ScrollingCoordinator* WebPage::scrollingCoordinator() const
     3155{
     3156    return m_page->scrollingCoordinator();
     3157}
     3158
    31543159WebPage::SandboxExtensionTracker::~SandboxExtensionTracker()
    31553160{
  • trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h

    r161358 r161387  
    184184    InjectedBundleBackForwardList* backForwardList();
    185185    DrawingArea* drawingArea() const { return m_drawingArea.get(); }
     186    WebCore::ScrollingCoordinator* scrollingCoordinator() const;
    186187
    187188    WebPageGroupProxy* pageGroup() const { return m_pageGroup.get(); }
  • trunk/Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h

    r161327 r161387  
    6565    virtual void setPageOverlayNeedsDisplay(PageOverlay*, const WebCore::IntRect&) OVERRIDE;
    6666    virtual void setPageOverlayOpacity(PageOverlay*, float) OVERRIDE;
     67    virtual bool supportsAsyncScrolling() OVERRIDE { return true; }
    6768
    6869    virtual void setLayerTreeStateIsFrozen(bool) OVERRIDE;
  • trunk/Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm

    r161327 r161387  
    3131#import "RemoteLayerTreeContext.h"
    3232#import "RemoteLayerTreeDrawingAreaProxyMessages.h"
     33#import "RemoteScrollingCoordinator.h"
     34#import "RemoteScrollingCoordinatorTransaction.h"
    3335#import "WebPage.h"
    3436#import <WebCore/Frame.h>
     
    320322    m_remoteLayerTreeContext->buildTransaction(layerTransaction, *m_rootLayer);
    321323
    322     m_webPage->send(Messages::RemoteLayerTreeDrawingAreaProxy::CommitLayerTree(layerTransaction));
     324    RemoteScrollingCoordinatorTransaction scrollingTransaction;
     325    if (m_webPage->scrollingCoordinator())
     326        toRemoteScrollingCoordinator(m_webPage->scrollingCoordinator())->buildTransaction(scrollingTransaction);
     327   
     328    m_webPage->send(Messages::RemoteLayerTreeDrawingAreaProxy::CommitLayerTree(layerTransaction, scrollingTransaction));
    323329}
    324330
Note: See TracChangeset for help on using the changeset viewer.