void PinchViewports::registerViewportLayersWithTreeView(WebLayerTreeView* layerTreeView) const
{
    ASSERT(layerTreeView);

    WebCore::RenderLayerCompositor* compositor = m_owner->compositor();
    GraphicsLayer* scrollLayer = compositor->scrollLayer();

    ASSERT(compositor);
    layerTreeView->registerViewportLayers(
        m_pageScaleLayer->platformLayer(),
        m_innerViewportScrollLayer->platformLayer(),
        scrollLayer->platformLayer());
}
Exemple #2
0
void PinchViewports::registerViewportLayersWithTreeView(WebLayerTreeView* layerTreeView) const
{
    if (!layerTreeView)
        return;

    WebCore::RenderLayerCompositor* compositor = m_owner->compositor();
    ASSERT(compositor);
    layerTreeView->registerPinchViewportLayers(
        m_innerViewportClipLayer->platformLayer(),
        m_pageScaleLayer->platformLayer(),
        m_innerViewportScrollLayer->platformLayer(),
        compositor->scrollLayer()->platformLayer(),
        m_overlayScrollbarHorizontal->platformLayer(),
        m_overlayScrollbarVertical->platformLayer());
}
Exemple #3
0
void PinchViewports::registerViewportLayersWithTreeView(WebLayerTreeView* layerTreeView) const
{
    ASSERT(layerTreeView);

    WebCore::RenderLayerCompositor* compositor = m_owner->compositor();
    // Get the outer viewport scroll layer.
    WebLayer* scrollLayer = compositor->scrollLayer()->platformLayer();

    m_webOverlayScrollbarHorizontal->setScrollLayer(scrollLayer);
    m_webOverlayScrollbarVertical->setScrollLayer(scrollLayer);

    ASSERT(compositor);
    layerTreeView->registerViewportLayers(
        m_pageScaleLayer->platformLayer(),
        m_innerViewportScrollLayer->platformLayer(),
        scrollLayer);
}