summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/platform/graphics/android
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/platform/graphics/android')
-rw-r--r--Source/WebCore/platform/graphics/android/layers/BaseLayerAndroid.cpp3
-rw-r--r--Source/WebCore/platform/graphics/android/layers/LayerAndroid.cpp4
2 files changed, 6 insertions, 1 deletions
diff --git a/Source/WebCore/platform/graphics/android/layers/BaseLayerAndroid.cpp b/Source/WebCore/platform/graphics/android/layers/BaseLayerAndroid.cpp
index 8069778..9ee97ac 100644
--- a/Source/WebCore/platform/graphics/android/layers/BaseLayerAndroid.cpp
+++ b/Source/WebCore/platform/graphics/android/layers/BaseLayerAndroid.cpp
@@ -89,7 +89,8 @@ void BaseLayerAndroid::updatePositionsRecursive(const SkRect& visibleContentRect
// dynamically increase in size to cover the viewport, and we cache its draw
// clip. This way the base layer will never have it's visible area clipped
// by its m_clippingRect, only the viewport.
- FloatRect clip(0, 0, 1e10, 1e10);
+ // Note: values larger than this suffer from floating point rounding issues
+ FloatRect clip(0, 0, 1e7, 1e7);
bool forcePositionCalculation = !m_positionsCalculated;
float scale = 1.0f;
diff --git a/Source/WebCore/platform/graphics/android/layers/LayerAndroid.cpp b/Source/WebCore/platform/graphics/android/layers/LayerAndroid.cpp
index 0f01fe2..d709a9c 100644
--- a/Source/WebCore/platform/graphics/android/layers/LayerAndroid.cpp
+++ b/Source/WebCore/platform/graphics/android/layers/LayerAndroid.cpp
@@ -273,6 +273,9 @@ void LayerAndroid::addDirtyArea()
return;
}
+ // TODO: rewrite this to handle partial invalidate, and to handle base
+ // layer's large clip correctly
+
IntSize layerSize(getSize().width(), getSize().height());
FloatRect area =
@@ -284,6 +287,7 @@ void LayerAndroid::addDirtyArea()
area.intersect(clip);
IntRect dirtyArea(area.x(), area.y(), area.width(), area.height());
+
state()->addDirtyArea(dirtyArea);
}