summaryrefslogtreecommitdiffstats
path: root/WebKit
diff options
context:
space:
mode:
authorNicolas Roard <nicolas@android.com>2010-01-07 14:22:22 +0000
committerNicolas Roard <nicolas@android.com>2010-01-14 21:09:00 +0000
commit388e461f3d6bf782b3cfb4bb21bc6264cef9323c (patch)
tree05bc536e78cf8385a91ceda4cb52cbd67eed2fa6 /WebKit
parent29b325cb949b1a41ac8bdeaa77977fcd342aec31 (diff)
downloadexternal_webkit-388e461f3d6bf782b3cfb4bb21bc6264cef9323c.zip
external_webkit-388e461f3d6bf782b3cfb4bb21bc6264cef9323c.tar.gz
external_webkit-388e461f3d6bf782b3cfb4bb21bc6264cef9323c.tar.bz2
Add proper support for fixed position elements
this is two-part change, see http://android-git.corp.google.com/g/#change,37092 for the java counterpart. This CL implements fixed position elements (css position: fixed) using layers, supporting pixels and percent lengths. It addresses http://b/1914365
Diffstat (limited to 'WebKit')
-rw-r--r--WebKit/android/nav/WebView.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/WebKit/android/nav/WebView.cpp b/WebKit/android/nav/WebView.cpp
index 0426337..1c98b87 100644
--- a/WebKit/android/nav/WebView.cpp
+++ b/WebKit/android/nav/WebView.cpp
@@ -1575,7 +1575,8 @@ static void nativeDrawMatches(JNIEnv *env, jobject obj, jobject canv)
}
static void nativeDrawLayers(JNIEnv *env, jobject obj,
- jint layer, jfloat scrollX, jfloat scrollY,
+ jint layer, jint scrollX, jint scrollY,
+ jint width, jint height,
jfloat scale, jobject canv)
{
if (!env)
@@ -1589,7 +1590,7 @@ static void nativeDrawLayers(JNIEnv *env, jobject obj,
LayerAndroid* layerImpl = reinterpret_cast<LayerAndroid*>(layer);
SkCanvas* canvas = GraphicsJNI::getNativeCanvas(env, canv);
if (canvas)
- layerImpl->paintOn(scrollX, scrollY, scale, canvas);
+ layerImpl->paintOn(scrollX, scrollY, width, height, scale, canvas);
#endif
}
@@ -2193,7 +2194,7 @@ static JNINativeMethod gJavaWebViewMethods[] = {
(void*) nativeLayersHaveAnimations },
{ "nativeEvaluateLayersAnimations", "(I)I",
(void*) nativeEvaluateLayersAnimations },
- { "nativeDrawLayers", "(IFFFLandroid/graphics/Canvas;)V",
+ { "nativeDrawLayers", "(IIIIIFLandroid/graphics/Canvas;)V",
(void*) nativeDrawLayers },
{ "nativeUpdateLayers", "(II)V",
(void*) nativeUpdateLayers },