diff options
-rw-r--r-- | WebKit/android/nav/WebView.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/WebKit/android/nav/WebView.cpp b/WebKit/android/nav/WebView.cpp index ea311ae..3a156de 100644 --- a/WebKit/android/nav/WebView.cpp +++ b/WebKit/android/nav/WebView.cpp @@ -1490,9 +1490,14 @@ class GLDrawFunctor : Functor { WebCore::IntRect inval; int titlebarHeight = webViewRect.height() - viewRect.height(); - bool retVal = (*wvInstance.*funcPtr)(viewRect, &inval, scale, extras); + + uirenderer::DrawGlInfo* info = reinterpret_cast<uirenderer::DrawGlInfo*>(data); + WebCore::IntRect localViewRect = viewRect; + if (info->isLayer) + localViewRect.move(-1 * localViewRect.x(), -1 * localViewRect.y()); + + bool retVal = (*wvInstance.*funcPtr)(localViewRect, &inval, scale, extras); if (retVal) { - uirenderer::DrawGlInfo* info = reinterpret_cast<uirenderer::DrawGlInfo*>(data); IntRect finalInval; if (inval.isEmpty()) { finalInval = webViewRect; |