diff options
Diffstat (limited to 'Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp')
-rw-r--r-- | Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp b/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp index 7b153848d..24a5aed18 100644 --- a/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp +++ b/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp @@ -30,7 +30,9 @@ #include "DrawingAreaProxyMessages.h" #include "LayerTreeContext.h" #include "UpdateInfo.h" +#include "WebPageGroup.h" #include "WebPageProxy.h" +#include "WebPreferences.h" #include "WebProcessProxy.h" #include <WebCore/Region.h> @@ -56,6 +58,11 @@ DrawingAreaProxyImpl::DrawingAreaProxyImpl(WebPageProxy* webPageProxy) , m_isBackingStoreDiscardable(true) , m_discardBackingStoreTimer(RunLoop::current(), this, &DrawingAreaProxyImpl::discardBackingStore) { +#if USE(TEXTURE_MAPPER) + // Construct the proxy early to allow messages to be sent to the web process while AC is entered there. + if (webPageProxy->pageGroup()->preferences()->forceCompositingMode()) + m_layerTreeHostProxy = adoptPtr(new LayerTreeHostProxy(this)); +#endif } DrawingAreaProxyImpl::~DrawingAreaProxyImpl() @@ -353,10 +360,16 @@ void DrawingAreaProxyImpl::setVisibleContentRectTrajectoryVector(const WebCore:: m_layerTreeHostProxy->setVisibleContentRectTrajectoryVector(trajectoryVector); } -void DrawingAreaProxyImpl::paintToCurrentGLContext(const TransformationMatrix& matrix, float opacity) +void DrawingAreaProxyImpl::paintLayerTree(BackingStore::PlatformGraphicsContext context) +{ + if (m_layerTreeHostProxy) + m_layerTreeHostProxy->paintToGraphicsContext(context); +} + +void DrawingAreaProxyImpl::paintToCurrentGLContext(const TransformationMatrix& matrix, float opacity, const FloatRect& clipRect) { if (m_layerTreeHostProxy) - m_layerTreeHostProxy->paintToCurrentGLContext(matrix, opacity); + m_layerTreeHostProxy->paintToCurrentGLContext(matrix, opacity, clipRect); } #endif |