summaryrefslogtreecommitdiffstats
path: root/WebCore/platform/graphics/android/LayerAndroid.cpp
diff options
context:
space:
mode:
authorNicolas Roard <nicolasroard@google.com>2011-03-22 14:29:12 -0700
committerNicolas Roard <nicolasroard@google.com>2011-03-22 23:56:44 -0700
commit772742124c1e5c700120019397dc8af29ced74c0 (patch)
treeb3a1d15332445f13f7a174d78587bc990dafd699 /WebCore/platform/graphics/android/LayerAndroid.cpp
parent55c8e9b1b75caff31e804a6f4da404da9f67af93 (diff)
downloadexternal_webkit-772742124c1e5c700120019397dc8af29ced74c0.zip
external_webkit-772742124c1e5c700120019397dc8af29ced74c0.tar.gz
external_webkit-772742124c1e5c700120019397dc8af29ced74c0.tar.bz2
Fix performance problems with layers
We were preventing the layers' positions to be updated while waiting for the base surface to render. This also fix some repainting issues. bug:4136077 Change-Id: I6870faf8296e205c6ee58e80b1cf95833a67814b
Diffstat (limited to 'WebCore/platform/graphics/android/LayerAndroid.cpp')
-rw-r--r--WebCore/platform/graphics/android/LayerAndroid.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/WebCore/platform/graphics/android/LayerAndroid.cpp b/WebCore/platform/graphics/android/LayerAndroid.cpp
index 009915e..dc40fb1 100644
--- a/WebCore/platform/graphics/android/LayerAndroid.cpp
+++ b/WebCore/platform/graphics/android/LayerAndroid.cpp
@@ -928,8 +928,10 @@ bool LayerAndroid::drawGL(GLWebViewState* glWebViewState, SkMatrix& matrix)
{
TilesManager::instance()->shader()->clip(m_clippingRect);
- if (prepareContext() && m_drawingTexture) {
+ if (m_drawingTexture) {
TextureInfo* textureInfo = m_drawingTexture->consumerLock();
+ if (!m_drawingTexture->readyFor(this))
+ m_dirty = true;
if (textureInfo) {
SkRect bounds;
bounds.set(m_drawingTexture->rect());
@@ -943,6 +945,8 @@ bool LayerAndroid::drawGL(GLWebViewState* glWebViewState, SkMatrix& matrix)
m_drawOpacity, true);
}
m_drawingTexture->consumerRelease();
+ } else {
+ m_dirty = true;
}
// When the layer is dirty, the UI thread should be notified to redraw.