OSDN Git Service

Merge WebKit at r76408: Fix calls to RenderLayer::scrollToOffset()
authorBen Murdoch <benm@google.com>
Tue, 17 May 2011 13:14:01 +0000 (14:14 +0100)
committerBen Murdoch <benm@google.com>
Mon, 23 May 2011 17:54:18 +0000 (18:54 +0100)
As of http://trac.webkit.org/changeset/76291 RenderLayer::scrollToOffset
only takes two parameters (the x and y offset). Update our callsites to
reflect this. It seems safe to disregard the booleans.

Change-Id: I63bc103e4fc961968055770792aead82be82435a

Source/WebCore/platform/graphics/android/GraphicsLayerAndroid.cpp
Source/WebKit/android/jni/WebViewCore.cpp
Source/WebKit/android/nav/CacheBuilder.cpp

index 57cb576..d7b792b 100644 (file)
@@ -572,10 +572,10 @@ bool GraphicsLayerAndroid::repaint()
 
             // Paint at 0,0.
             IntSize scroll = layer->scrolledContentOffset();
-            layer->scrollToOffset(0, 0, true, false);
+            layer->scrollToOffset(0, 0);
             // At this point, it doesn't matter if painting failed.
             (void) paintContext(m_foregroundLayer->recordContext(), contentsRect);
-            layer->scrollToOffset(scroll.width(), scroll.height(), true, false);
+            layer->scrollToOffset(scroll.width(), scroll.height());
 
             // Construct the clip layer for masking the contents.
             IntRect clip = layer->renderer()->absoluteBoundingBoxRect();
index f2680b5..d7f60d3 100644 (file)
@@ -3726,7 +3726,7 @@ void WebViewCore::scrollRenderLayer(int layer, const SkRect& rect)
         return;
 
     if (owner->stackingContext())
-        owner->scrollToOffset(rect.fLeft, rect.fTop, true, false);
+        owner->scrollToOffset(rect.fLeft, rect.fTop);
 #endif
 }
 
index dc10f21..e7691d7 100644 (file)
@@ -100,7 +100,7 @@ CacheBuilder::LayerTracker::~LayerTracker() {
     if (mRenderLayer && mRenderLayer->stackingContext())
         // Restore the scroll position of the layer.  Does not affect layers
         // without overflow scroll as the layer will not be scrolled.
-        mRenderLayer->scrollToOffset(mScroll.x(), mScroll.y(), false, false);
+        mRenderLayer->scrollToOffset(mScroll.x(), mScroll.y());
 }
 
 #if DUMP_NAV_CACHE
@@ -2930,7 +2930,7 @@ void CacheBuilder::TrackLayer(WTF::Vector<LayerTracker>& layerTracker,
         return;
     // Prevent a crash when scrolling a layer that does not have a parent.
     if (layer->stackingContext())
-        layer->scrollToOffset(0, 0, false, false);
+        layer->scrollToOffset(0, 0);
 #endif
     layerTracker.grow(layerTracker.size() + 1);
     LayerTracker& indexTracker = layerTracker.last();