summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/platform/graphics/android/rendering/Surface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/platform/graphics/android/rendering/Surface.cpp')
-rw-r--r--Source/WebCore/platform/graphics/android/rendering/Surface.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/Source/WebCore/platform/graphics/android/rendering/Surface.cpp b/Source/WebCore/platform/graphics/android/rendering/Surface.cpp
index 96a4a16..6caf93b 100644
--- a/Source/WebCore/platform/graphics/android/rendering/Surface.cpp
+++ b/Source/WebCore/platform/graphics/android/rendering/Surface.cpp
@@ -52,7 +52,7 @@ namespace WebCore {
Surface::Surface()
: m_surfaceBacking(0)
, m_needsTexture(false)
- , m_hasText(false)
+ , m_maxZoomScale(1)
{
#ifdef DEBUG_COUNT
ClassTracker::instance()->increment("Surface");
@@ -140,7 +140,7 @@ void Surface::addLayer(LayerAndroid* layer, const TransformationMatrix& transfor
SkSafeRef(layer);
m_needsTexture |= layer->needsTexture();
- m_hasText |= layer->hasText();
+ m_maxZoomScale = std::max(m_maxZoomScale, layer->maxZoomScale());
// add this layer's size to the surface's area
// TODO: handle scale/3d transform mapping
@@ -211,7 +211,6 @@ void Surface::prepareGL(bool layerTilesDisabled, bool updateWithBlit)
if (tilesDisabled) {
m_surfaceBacking->discardTextures();
} else {
- bool allowZoom = hasText(); // only allow for scale > 1 if painting vectors
IntRect prepareArea = computePrepareArea();
IntRect fullArea = fullContentArea();
@@ -223,7 +222,7 @@ void Surface::prepareGL(bool layerTilesDisabled, bool updateWithBlit)
prepareArea.x(), prepareArea.y(), prepareArea.width(), prepareArea.height(),
fullArea.x(), fullArea.y(), fullArea.width(), fullArea.height());
- m_surfaceBacking->prepareGL(getFirstLayer()->state(), allowZoom,
+ m_surfaceBacking->prepareGL(getFirstLayer()->state(), m_maxZoomScale,
prepareArea, fullArea,
this, useAggressiveRendering(), updateWithBlit);
}