diff options
author | Teng-Hui Zhu <ztenghui@google.com> | 2011-05-17 16:02:02 -0700 |
---|---|---|
committer | Teng-Hui Zhu <ztenghui@google.com> | 2011-05-18 14:27:37 -0700 |
commit | e61ae1cb52fb14cf18cef0044ed125e162c8c2dd (patch) | |
tree | 51c824458f462243c267f18a531c446c911859db | |
parent | 58348114645f3987aaabae40612a876cfd2bc678 (diff) | |
download | external_webkit-e61ae1cb52fb14cf18cef0044ed125e162c8c2dd.zip external_webkit-e61ae1cb52fb14cf18cef0044ed125e162c8c2dd.tar.gz external_webkit-e61ae1cb52fb14cf18cef0044ed125e162c8c2dd.tar.bz2 |
DO NOT MERGE: Partially revert change from 96777
By reverting this part, the preview is scrolling fine now.
The old bug 3416512 is kept fixed.
bug:4440227
Change-Id: I3e7639b29ec818ccc9553fd459ac53f13752a1e2
-rw-r--r-- | WebCore/platform/graphics/android/GraphicsLayerAndroid.cpp | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/WebCore/platform/graphics/android/GraphicsLayerAndroid.cpp b/WebCore/platform/graphics/android/GraphicsLayerAndroid.cpp index 59f8408..4198608 100644 --- a/WebCore/platform/graphics/android/GraphicsLayerAndroid.cpp +++ b/WebCore/platform/graphics/android/GraphicsLayerAndroid.cpp @@ -273,24 +273,14 @@ void GraphicsLayerAndroid::setPosition(const FloatPoint& point) if (point == m_position) return; - FloatPoint pos(point); -#if ENABLE(ANDROID_OVERFLOW_SCROLL) - // Add the scroll position back in. When scrolling a layer, all the children - // are positioned based on the content scroll. Adding the scroll position - // back in allows the children to draw based on 0,0. - RenderLayer* layer = renderLayerFromClient(m_client); - if (layer && layer->parent() && layer->parent()->hasOverflowScroll()) - pos += layer->parent()->scrolledContentOffset(); -#endif - - GraphicsLayer::setPosition(pos); + GraphicsLayer::setPosition(point); #ifdef LAYER_DEBUG_2 LOG("(%x) setPosition(%.2f,%.2f) pos(%.2f, %.2f) anchor(%.2f,%.2f) size(%.2f, %.2f)", this, point.x(), point.y(), m_position.x(), m_position.y(), m_anchorPoint.x(), m_anchorPoint.y(), m_size.width(), m_size.height()); #endif - m_contentLayer->setPosition(pos.x(), pos.y()); + m_contentLayer->setPosition(point.x(), point.y()); askForSync(); } |