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 }
void QGraphicsWKViewPrivate::commitScale() { #if ENABLE(TILED_BACKING_STORE) DrawingAreaProxy* drawingArea = page->d->page->drawingArea(); float newScale = q->scale(); if (drawingArea->info().type == DrawingAreaProxy::TiledDrawingAreaType) { TiledDrawingAreaProxy* tiledDrawingArea = static_cast<TiledDrawingAreaProxy*>(drawingArea); if (tiledDrawingArea->contentsScale() == newScale) return; tiledDrawingArea->setContentsScale(newScale); // For now we block until complete. tiledDrawingArea->waitUntilUpdatesComplete(); } #endif }