当前位置: 首页>>代码示例>>C++>>正文


C++ DrawingAreaProxy类代码示例

本文整理汇总了C++中DrawingAreaProxy的典型用法代码示例。如果您正苦于以下问题:C++ DrawingAreaProxy类的具体用法?C++ DrawingAreaProxy怎么用?C++ DrawingAreaProxy使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了DrawingAreaProxy类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: resetPaintNode

void QQuickWebPagePrivate::resetPaintNode()
{
    m_paintNode = 0;
    DrawingAreaProxy* drawingArea = webPageProxy->drawingArea();
    if (drawingArea && drawingArea->layerTreeHostProxy())
        drawingArea->layerTreeHostProxy()->purgeGLResources();
}
开发者ID:,项目名称:,代码行数:7,代码来源:

示例2: setDrawingAreaSize

void QQuickWebPagePrivate::setDrawingAreaSize(const QSize& size)
{
    DrawingAreaProxy* drawingArea = webPageProxy->drawingArea();
    if (!drawingArea)
        return;
    drawingArea->setSize(WebCore::IntSize(size), WebCore::IntSize());
}
开发者ID:,项目名称:,代码行数:7,代码来源:

示例3: page

void WebViewNix::didChangeContentPosition(const WebCore::FloatPoint& trajectoryVector)
{
    DrawingAreaProxy* drawingArea = page()->drawingArea();
    if (!drawingArea)
        return;
    FloatRect visibleContentsRect(contentPosition(), visibleContentsSize());
    visibleContentsRect.intersect(FloatRect(FloatPoint(), contentsSize()));
    drawingArea->setVisibleContentsRect(visibleContentsRect, trajectoryVector);
}
开发者ID:,项目名称:,代码行数:9,代码来源:

示例4: ENABLE

void QGraphicsWKView::takeSnapshot(const QSize& size, const QRect& contentsRect)
{
#if ENABLE(TILED_BACKING_STORE)
    DrawingAreaProxy* drawingArea = page()->d->page->drawingArea();
    if (drawingArea->info().type != DrawingAreaProxy::TiledDrawingAreaType)
        return;
    TiledDrawingAreaProxy* tiledDrawingArea = static_cast<TiledDrawingAreaProxy*>(drawingArea);
    tiledDrawingArea->takeSnapshot(size, contentsRect);
#endif
}
开发者ID:achellies,项目名称:WinCEWebKit,代码行数:10,代码来源:qgraphicswkview.cpp

示例5: ASSERT_NOT_REACHED

const RemoteLayerTreeHost* RemoteScrollingCoordinatorProxy::layerTreeHost() const
{
    DrawingAreaProxy* drawingArea = m_webPageProxy.drawingArea();
    if (!drawingArea || drawingArea->type() != DrawingAreaTypeRemoteLayerTree) {
        ASSERT_NOT_REACHED();
        return nullptr;
    }

    RemoteLayerTreeDrawingAreaProxy* remoteDrawingArea = toRemoteLayerTreeDrawingAreaProxy(drawingArea);
    return &remoteDrawingArea->remoteLayerTreeHost();
}
开发者ID:Wrichik1999,项目名称:webkit,代码行数:11,代码来源:RemoteScrollingCoordinatorProxy.cpp

示例6: coordinatedGraphicsScene

CoordinatedGraphicsScene* WebView::coordinatedGraphicsScene()
{
    DrawingAreaProxy* drawingArea = m_page->drawingArea();
    if (!drawingArea)
        return 0;

    WebKit::CoordinatedLayerTreeHostProxy* layerTreeHostProxy = drawingArea->coordinatedLayerTreeHostProxy();
    if (!layerTreeHostProxy)
        return 0;

    return layerTreeHostProxy->coordinatedGraphicsScene();
}
开发者ID:massa84,项目名称:phantomjs-webkit,代码行数:12,代码来源:WebView.cpp

示例7: syncVisibleContents

void PageViewportController::syncVisibleContents(const FloatPoint& trajectoryVector)
{
    DrawingAreaProxy* drawingArea = m_webPageProxy->drawingArea();
    if (!drawingArea || m_viewportSize.isEmpty() || m_contentsSize.isEmpty())
        return;

    FloatRect visibleContentsRect(clampViewportToContents(m_viewportPos, m_effectiveScale), viewportSizeInContentsCoordinates());
    visibleContentsRect.intersect(FloatRect(FloatPoint::zero(), m_contentsSize));
    drawingArea->setVisibleContentsRect(visibleContentsRect, m_effectiveScale, trajectoryVector);

    m_client->didChangeVisibleContents();
}
开发者ID:anger123520,项目名称:qtwebkit-23_from_gitorious,代码行数:12,代码来源:PageViewportController.cpp

示例8: ENABLE

void QGraphicsWKViewPrivate::commitScale()
{
#if ENABLE(TILED_BACKING_STORE)
    DrawingAreaProxy* drawingArea = page->d->page->drawingArea();
    float newScale = q->scale();
    if (drawingArea->type() == DrawingAreaTypeTiled) {
        TiledDrawingAreaProxy* tiledDrawingArea = static_cast<TiledDrawingAreaProxy*>(drawingArea);
        if (tiledDrawingArea->contentsScale() == newScale)
            return;
        tiledDrawingArea->setContentsScale(newScale);
    }
#endif
}
开发者ID:,项目名称:,代码行数:13,代码来源:

示例9: computeEffectiveOpacity

void QQuickWebPagePrivate::paintToCurrentGLContext()
{
    if (!q->isVisible())
        return;

    QTransform transform = q->itemTransform(0, 0);
    transform.scale(contentsScale, contentsScale);

    float opacity = computeEffectiveOpacity(q);
    QRectF clipRect = viewportItem->mapRectToScene(viewportItem->boundingRect());

    if (!clipRect.isValid())
        return;

    DrawingAreaProxy* drawingArea = webPageProxy->drawingArea();
    if (!drawingArea)
        return;

    drawingArea->paintToCurrentGLContext(transform, opacity, clipRect);
}
开发者ID:,项目名称:,代码行数:20,代码来源:

示例10: informVisibleContentChange

void QtViewportHandler::informVisibleContentChange(const QPointF& trajectoryVector)
{
    DrawingAreaProxy* drawingArea = m_webPageProxy->drawingArea();
    if (!drawingArea)
        return;

    if (m_lastVisibleContentsRect == visibleContentsRect())
        return;

    qreal scale = m_pageItem->contentsScale();

    if (scale != m_lastCommittedScale)
        emit m_viewportItem->experimental()->test()->contentsScaleCommitted();
    m_lastCommittedScale = scale;
    m_lastVisibleContentsRect = visibleContentsRect();

    drawingArea->setVisibleContentsRect(visibleContentsRect(), scale, trajectoryVector, m_viewportItem->contentPos());

    // Ensure that updatePaintNode is always called before painting.
    m_pageItem->update();
}
开发者ID:,项目名称:,代码行数:21,代码来源:

示例11: updateSize

void QQuickWebPagePrivate::updateSize()
{
    QSizeF scaledSize = contentsSize * contentsScale;

    DrawingAreaProxy* drawingArea = webPageProxy->drawingArea();
    if (drawingArea && drawingArea->layerTreeHostProxy())
        drawingArea->layerTreeHostProxy()->setContentsSize(contentsSize);

    q->setSize(scaledSize);

    if (viewportItem->experimental()->flickableViewportEnabled()) {
        // Make sure that the content is sized to the page if the user did not
        // add other flickable items. If that is not the case, the user needs to
        // disable the default content item size property on the WebView and
        // bind the contentWidth and contentHeight accordingly, in accordance
        // accordance with normal Flickable behaviour.
        if (viewportItem->experimental()->useDefaultContentItemSize()) {
            viewportItem->setContentWidth(scaledSize.width());
            viewportItem->setContentHeight(scaledSize.height());
        }
    }
}
开发者ID:dzhshf,项目名称:WebKit,代码行数:22,代码来源:qquickwebpage.cpp


注:本文中的DrawingAreaProxy类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。