| Index: third_party/WebKit/Source/platform/scroll/ScrollAnimatorTest.cpp
|
| diff --git a/third_party/WebKit/Source/platform/scroll/ScrollAnimatorTest.cpp b/third_party/WebKit/Source/platform/scroll/ScrollAnimatorTest.cpp
|
| index 78d121446e8c4f6fa5e67c6db2c3b4b64e18d428..b0f969f2d93385c04d8925361e3767a913e01dbe 100644
|
| --- a/third_party/WebKit/Source/platform/scroll/ScrollAnimatorTest.cpp
|
| +++ b/third_party/WebKit/Source/platform/scroll/ScrollAnimatorTest.cpp
|
| @@ -62,7 +62,7 @@ class MockScrollableArea : public GarbageCollectedFinalized<MockScrollableArea>,
|
| MOCK_CONST_METHOD1(scrollSize, int(ScrollbarOrientation));
|
| MOCK_CONST_METHOD0(isScrollCornerVisible, bool());
|
| MOCK_CONST_METHOD0(scrollCornerRect, IntRect());
|
| - MOCK_METHOD2(setScrollOffset, void(const DoublePoint&, ScrollType));
|
| + MOCK_METHOD2(updateScrollPosition, void(const DoublePoint&, ScrollType));
|
| MOCK_METHOD0(scrollControlWasSetNeedsPaintInvalidation, void());
|
| MOCK_CONST_METHOD0(enclosingScrollableArea, ScrollableArea*());
|
| MOCK_CONST_METHOD0(minimumScrollPosition, IntPoint());
|
| @@ -160,7 +160,7 @@ TEST(ScrollAnimatorTest, MainThreadStates) {
|
| EXPECT_CALL(*scrollableArea, maximumScrollPosition())
|
| .Times(AtLeast(1))
|
| .WillRepeatedly(Return(IntPoint(1000, 1000)));
|
| - EXPECT_CALL(*scrollableArea, setScrollOffset(_, _)).Times(2);
|
| + EXPECT_CALL(*scrollableArea, updateScrollPosition(_, _)).Times(2);
|
| // Once from userScroll, once from updateCompositorAnimations.
|
| EXPECT_CALL(*scrollableArea, registerForAnimation()).Times(2);
|
| EXPECT_CALL(*scrollableArea, scheduleAnimation())
|
| @@ -216,7 +216,7 @@ TEST(ScrollAnimatorTest, MainThreadEnabled) {
|
| EXPECT_CALL(*scrollableArea, maximumScrollPosition())
|
| .Times(AtLeast(1))
|
| .WillRepeatedly(Return(IntPoint(1000, 1000)));
|
| - EXPECT_CALL(*scrollableArea, setScrollOffset(_, _)).Times(9);
|
| + EXPECT_CALL(*scrollableArea, updateScrollPosition(_, _)).Times(9);
|
| EXPECT_CALL(*scrollableArea, registerForAnimation()).Times(6);
|
| EXPECT_CALL(*scrollableArea, scheduleAnimation())
|
| .Times(AtLeast(1))
|
| @@ -300,7 +300,7 @@ TEST(ScrollAnimatorTest, AnimatedScrollAborted) {
|
| EXPECT_CALL(*scrollableArea, maximumScrollPosition())
|
| .Times(AtLeast(1))
|
| .WillRepeatedly(Return(IntPoint(1000, 1000)));
|
| - EXPECT_CALL(*scrollableArea, setScrollOffset(_, _)).Times(3);
|
| + EXPECT_CALL(*scrollableArea, updateScrollPosition(_, _)).Times(3);
|
| EXPECT_CALL(*scrollableArea, registerForAnimation()).Times(2);
|
| EXPECT_CALL(*scrollableArea, scheduleAnimation())
|
| .Times(AtLeast(1))
|
| @@ -351,7 +351,7 @@ TEST(ScrollAnimatorTest, AnimatedScrollTakeover) {
|
| EXPECT_CALL(*scrollableArea, maximumScrollPosition())
|
| .Times(AtLeast(1))
|
| .WillRepeatedly(Return(IntPoint(1000, 1000)));
|
| - EXPECT_CALL(*scrollableArea, setScrollOffset(_, _)).Times(2);
|
| + EXPECT_CALL(*scrollableArea, updateScrollPosition(_, _)).Times(2);
|
| // Called from userScroll, updateCompositorAnimations, then
|
| // takeOverCompositorAnimation (to re-register after RunningOnCompositor).
|
| EXPECT_CALL(*scrollableArea, registerForAnimation()).Times(3);
|
| @@ -405,7 +405,7 @@ TEST(ScrollAnimatorTest, Disabled) {
|
| EXPECT_CALL(*scrollableArea, maximumScrollPosition())
|
| .Times(AtLeast(1))
|
| .WillRepeatedly(Return(IntPoint(1000, 1000)));
|
| - EXPECT_CALL(*scrollableArea, setScrollOffset(_, _)).Times(8);
|
| + EXPECT_CALL(*scrollableArea, updateScrollPosition(_, _)).Times(8);
|
| EXPECT_CALL(*scrollableArea, registerForAnimation()).Times(0);
|
|
|
| scrollAnimator->userScroll(ScrollByLine, FloatSize(100, 0));
|
| @@ -443,7 +443,7 @@ TEST(ScrollAnimatorTest, CancellingAnimationResetsState) {
|
| .Times(AtLeast(1))
|
| .WillRepeatedly(Return(IntPoint(1000, 1000)));
|
| // Called from first userScroll, setCurrentPosition, and second userScroll.
|
| - EXPECT_CALL(*scrollableArea, setScrollOffset(_, _)).Times(3);
|
| + EXPECT_CALL(*scrollableArea, updateScrollPosition(_, _)).Times(3);
|
| // Called from userScroll, updateCompositorAnimations.
|
| EXPECT_CALL(*scrollableArea, registerForAnimation()).Times(4);
|
| EXPECT_CALL(*scrollableArea, scheduleAnimation())
|
| @@ -511,7 +511,7 @@ TEST(ScrollAnimatorTest, CancellingCompositorAnimation) {
|
| .Times(AtLeast(1))
|
| .WillRepeatedly(Return(IntPoint(1000, 1000)));
|
| // Called when reset, not setting anywhere else.
|
| - EXPECT_CALL(*scrollableArea, setScrollOffset(_, _)).Times(1);
|
| + EXPECT_CALL(*scrollableArea, updateScrollPosition(_, _)).Times(1);
|
| // Called from userScroll, and first update.
|
| EXPECT_CALL(*scrollableArea, registerForAnimation()).Times(4);
|
| EXPECT_CALL(*scrollableArea, scheduleAnimation())
|
| @@ -630,7 +630,7 @@ TEST(ScrollAnimatorTest, MainThreadAnimationTargetAdjustment) {
|
| .WillRepeatedly(Return(IntPoint(1000, 1000)));
|
| // Twice from tickAnimation, once from reset, and twice from
|
| // adjustAnimationAndSetScrollPosition.
|
| - EXPECT_CALL(*scrollableArea, setScrollOffset(_, _)).Times(5);
|
| + EXPECT_CALL(*scrollableArea, updateScrollPosition(_, _)).Times(5);
|
| // One from call to userScroll and one from updateCompositorAnimations.
|
| EXPECT_CALL(*scrollableArea, registerForAnimation()).Times(2);
|
| EXPECT_CALL(*scrollableArea, scheduleAnimation())
|
|
|