Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1666)

Unified Diff: cc/layer_tree_host_impl_unittest.cc

Issue 11293121: Add latency measurement system (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: create cc::LatencyInfo Created 7 years, 12 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/layer_tree_host_impl.cc ('k') | cc/layer_tree_host_unittest_scroll.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layer_tree_host_impl_unittest.cc
diff --git a/cc/layer_tree_host_impl_unittest.cc b/cc/layer_tree_host_impl_unittest.cc
index af6082d5d674291520c12615206b4276dd5107f5..af5fed3e0a1df76b638983bb4d3bf4320ce07243 100644
--- a/cc/layer_tree_host_impl_unittest.cc
+++ b/cc/layer_tree_host_impl_unittest.cc
@@ -100,6 +100,7 @@ public:
virtual void postAnimationEventsToMainThreadOnImplThread(scoped_ptr<AnimationEventsVector>, base::Time wallClockTime) OVERRIDE { }
virtual bool reduceContentsTextureMemoryOnImplThread(size_t limitBytes, int priorityCutoff) OVERRIDE { return m_reduceMemoryResult; }
virtual void sendManagedMemoryStats() OVERRIDE { }
+ virtual void onReceivedLatencyInfo(const LatencyInfo& latencyInfo) OVERRIDE { }
void setReduceMemoryResult(bool reduceMemoryResult) { m_reduceMemoryResult = reduceMemoryResult; }
@@ -364,7 +365,7 @@ TEST_P(LayerTreeHostImplTest, scrollRootCallsCommitAndRedraw)
initializeRendererAndDrawFrame();
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, 10));
+ m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, 10));
m_hostImpl->scrollEnd();
EXPECT_TRUE(m_didRequestRedraw);
EXPECT_TRUE(m_didRequestCommit);
@@ -407,7 +408,7 @@ TEST_P(LayerTreeHostImplTest, replaceTreeWhileScrolling)
// We should still be scrolling, because the scrolled layer also exists in the new tree.
gfx::Vector2d scrollDelta(0, 10);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
scoped_ptr<ScrollAndScaleSet> scrollInfo = m_hostImpl->processScrollDeltas();
expectContains(*scrollInfo, scrollLayerId, scrollDelta);
@@ -473,10 +474,10 @@ TEST_P(LayerTreeHostImplTest, nonFastScrollableRegionBasic)
// All scroll types outside this region should succeed.
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(75, 75), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, 10));
+ m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, 10));
m_hostImpl->scrollEnd();
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(75, 75), InputHandlerClient::Gesture), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, 10));
+ m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, 10));
m_hostImpl->scrollEnd();
}
@@ -494,7 +495,7 @@ TEST_P(LayerTreeHostImplTest, nonFastScrollableRegionWithOffset)
// This point would fall into the non-fast scrollable region except that we've moved the layer down by 25 pixels.
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(40, 10), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, 1));
+ m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, 1));
m_hostImpl->scrollEnd();
// This point is still inside the non-fast region.
@@ -512,27 +513,27 @@ TEST_P(LayerTreeHostImplTest, scrollByReturnsCorrectValue)
m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
// Trying to scroll to the left/top will not succeed.
- EXPECT_FALSE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(-10, 0)));
- EXPECT_FALSE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, -10)));
- EXPECT_FALSE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(-10, -10)));
+ EXPECT_FALSE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(-10, 0)));
+ EXPECT_FALSE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, -10)));
+ EXPECT_FALSE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(-10, -10)));
// Scrolling to the right/bottom will succeed.
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(10, 0)));
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, 10)));
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(10, 10)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(10, 0)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, 10)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(10, 10)));
// Scrolling to left/top will now succeed.
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(-10, 0)));
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, -10)));
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(-10, -10)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(-10, 0)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, -10)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(-10, -10)));
// Scrolling diagonally against an edge will succeed.
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(10, -10)));
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(-10, 0)));
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(-10, 10)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(10, -10)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(-10, 0)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(-10, 10)));
// Trying to scroll more than the available space will also succeed.
- EXPECT_TRUE(m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(5000, 5000)));
+ EXPECT_TRUE(m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(5000, 5000)));
}
TEST_P(LayerTreeHostImplTest, maxScrollOffsetChangedByDeviceScaleFactor)
@@ -601,7 +602,7 @@ TEST_P(LayerTreeHostImplTest, implPinchZoom)
gfx::Vector2d scrollDelta(0, 10);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(5, 5), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
scoped_ptr<ScrollAndScaleSet> scrollInfo = m_hostImpl->processScrollDeltas();
@@ -706,7 +707,7 @@ TEST_P(LayerTreeHostImplTest, pinchGesture)
m_hostImpl->scrollBegin(gfx::Point(10, 10), InputHandlerClient::Wheel);
m_hostImpl->pinchGestureBegin();
m_hostImpl->pinchGestureUpdate(pageScaleDelta, gfx::Point(10, 10));
- m_hostImpl->scrollBy(gfx::Point(10, 10), gfx::Vector2d(-10, -10));
+ m_hostImpl->scrollBy(0, gfx::Point(10, 10), gfx::Vector2d(-10, -10));
m_hostImpl->pinchGestureUpdate(pageScaleDelta, gfx::Point(20, 20));
m_hostImpl->pinchGestureEnd();
m_hostImpl->scrollEnd();
@@ -873,7 +874,7 @@ TEST_P(LayerTreeHostImplTest, inhibitScrollAndPageScaleUpdatesWhileAnimatingPage
// Scrolling during the animation is ignored.
const gfx::Vector2d scrollDelta(0, 10);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(target.x(), target.y()), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
// The final page scale and scroll deltas should match what we got
@@ -1147,7 +1148,7 @@ TEST_P(LayerTreeHostImplTest, scrollNonCompositedRoot)
initializeRendererAndDrawFrame();
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(5, 5), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, 10));
+ m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, 10));
m_hostImpl->scrollEnd();
EXPECT_TRUE(m_didRequestRedraw);
EXPECT_TRUE(m_didRequestCommit);
@@ -1165,7 +1166,7 @@ TEST_P(LayerTreeHostImplTest, scrollChildCallsCommitAndRedraw)
initializeRendererAndDrawFrame();
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(5, 5), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gfx::Vector2d(0, 10));
+ m_hostImpl->scrollBy(0, gfx::Point(), gfx::Vector2d(0, 10));
m_hostImpl->scrollEnd();
EXPECT_TRUE(m_didRequestRedraw);
EXPECT_TRUE(m_didRequestCommit);
@@ -1240,7 +1241,7 @@ TEST_P(LayerTreeHostImplTest, scrollRootAndChangePageScaleOnMainThread)
gfx::Vector2d expectedScrollDelta(scrollDelta);
gfx::Vector2d expectedMaxScroll(m_hostImpl->rootLayer()->maxScrollOffset());
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(5, 5), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
// Set new page scale from main thread.
@@ -1293,7 +1294,7 @@ TEST_P(LayerTreeHostImplTest, scrollRootAndChangePageScaleOnImplThread)
gfx::Vector2d expectedScrollDelta(scrollDelta);
gfx::Vector2d expectedMaxScroll(m_hostImpl->rootLayer()->maxScrollOffset());
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(5, 5), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
// Set new page scale on impl thread by pinching.
@@ -1380,7 +1381,7 @@ TEST_P(LayerTreeHostImplTest, scrollChildAndChangePageScaleOnMainThread)
gfx::Vector2d expectedScrollDelta(scrollDelta);
gfx::Vector2d expectedMaxScroll(child->maxScrollOffset());
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(5, 5), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
float pageScale = 2;
@@ -1425,7 +1426,7 @@ TEST_P(LayerTreeHostImplTest, scrollChildBeyondLimit)
{
gfx::Vector2d scrollDelta(-8, -7);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(5, 5), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
scoped_ptr<ScrollAndScaleSet> scrollInfo = m_hostImpl->processScrollDeltas();
@@ -1457,7 +1458,7 @@ TEST_P(LayerTreeHostImplTest, scrollEventBubbling)
{
gfx::Vector2d scrollDelta(0, 4);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(5, 5), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
scoped_ptr<ScrollAndScaleSet> scrollInfo = m_hostImpl->processScrollDeltas();
@@ -1499,7 +1500,7 @@ TEST_P(LayerTreeHostImplTest, scrollAxisAlignedRotatedLayer)
// Scroll to the right in screen coordinates with a gesture.
gfx::Vector2d gestureScrollDelta(10, 0);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gestureScrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), gestureScrollDelta);
m_hostImpl->scrollEnd();
// The layer should have scrolled down in its local coordinates.
@@ -1510,7 +1511,7 @@ TEST_P(LayerTreeHostImplTest, scrollAxisAlignedRotatedLayer)
m_hostImpl->rootLayer()->setScrollDelta(gfx::Vector2dF());
gfx::Vector2d wheelScrollDelta(0, 10);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), wheelScrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), wheelScrollDelta);
m_hostImpl->scrollEnd();
// The layer should have scrolled down in its local coordinates.
@@ -1544,7 +1545,7 @@ TEST_P(LayerTreeHostImplTest, scrollNonAxisAlignedRotatedLayer)
// Scroll down in screen coordinates with a gesture.
gfx::Vector2d gestureScrollDelta(0, 10);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gestureScrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), gestureScrollDelta);
m_hostImpl->scrollEnd();
// The child layer should have scrolled down in its local coordinates an amount proportional to
@@ -1563,7 +1564,7 @@ TEST_P(LayerTreeHostImplTest, scrollNonAxisAlignedRotatedLayer)
m_hostImpl->rootLayer()->children()[1]->setScrollDelta(gfx::Vector2dF());
gfx::Vector2d gestureScrollDelta(10, 0);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), gestureScrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), gestureScrollDelta);
m_hostImpl->scrollEnd();
// The child layer should have scrolled down in its local coordinates an amount proportional to
@@ -1596,7 +1597,7 @@ TEST_P(LayerTreeHostImplTest, scrollScaledLayer)
// Scroll down in screen coordinates with a gesture.
gfx::Vector2d scrollDelta(0, 10);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
// The layer should have scrolled down in its local coordinates, but half he amount.
@@ -1607,7 +1608,7 @@ TEST_P(LayerTreeHostImplTest, scrollScaledLayer)
m_hostImpl->rootLayer()->setScrollDelta(gfx::Vector2dF());
gfx::Vector2d wheelScrollDelta(0, 10);
EXPECT_EQ(m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Wheel), InputHandlerClient::ScrollStarted);
- m_hostImpl->scrollBy(gfx::Point(), wheelScrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), wheelScrollDelta);
m_hostImpl->scrollEnd();
// The scale should not have been applied to the scroll delta.
@@ -4482,7 +4483,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportForcesCommitRedraw(const float d
// This scroll will force the viewport to pan horizontally.
gfx::Vector2d scrollDelta(5, 0);
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
EXPECT_EQ(true, m_didRequestCommit);
@@ -4494,7 +4495,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportForcesCommitRedraw(const float d
// This scroll will force the viewport to pan vertically.
scrollDelta = gfx::Vector2d(0, 5);
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDelta);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDelta);
m_hostImpl->scrollEnd();
EXPECT_EQ(true, m_didRequestCommit);
@@ -4553,7 +4554,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportTest(const float deviceScaleFact
gfx::Vector2d scrollDeltaInZoomedViewport = ToFlooredVector2d(gfx::ScaleVector2d(scrollDelta, m_hostImpl->totalPageScaleFactorForTesting()));
gfx::Vector2d expectedMaxScroll(m_hostImpl->rootLayer()->maxScrollOffset());
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDeltaInZoomedViewport);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDeltaInZoomedViewport);
m_hostImpl->scrollEnd();
drawOneFrame();
@@ -4571,7 +4572,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportTest(const float deviceScaleFact
scrollDelta = gfx::Vector2d(0, 5);
scrollDeltaInZoomedViewport = ToFlooredVector2d(gfx::ScaleVector2d(scrollDelta, m_hostImpl->totalPageScaleFactorForTesting()));
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDeltaInZoomedViewport);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDeltaInZoomedViewport);
m_hostImpl->scrollEnd();
drawOneFrame();
@@ -4638,7 +4639,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportAndScrollTest(const float device
gfx::Vector2d expectedScrollDelta(scrollDelta);
gfx::Vector2d expectedMaxScroll(m_hostImpl->rootLayer()->maxScrollOffset());
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDeltaInZoomedViewport);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDeltaInZoomedViewport);
m_hostImpl->scrollEnd();
drawOneFrame();
@@ -4654,7 +4655,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportAndScrollTest(const float device
scrollDelta = gfx::Vector2d(2, 0);
scrollDeltaInZoomedViewport = ToFlooredVector2d(gfx::ScaleVector2d(scrollDelta, m_hostImpl->totalPageScaleFactorForTesting()));
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDeltaInZoomedViewport);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDeltaInZoomedViewport);
m_hostImpl->scrollEnd();
drawOneFrame();
@@ -4675,7 +4676,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportAndScrollTest(const float device
scrollDeltaInZoomedViewport = ToFlooredVector2d(gfx::ScaleVector2d(scrollDelta, m_hostImpl->totalPageScaleFactorForTesting()));
expectedScrollDelta += scrollDelta;
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDeltaInZoomedViewport);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDeltaInZoomedViewport);
m_hostImpl->scrollEnd();
drawOneFrame();
@@ -4691,7 +4692,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportAndScrollTest(const float device
scrollDelta = gfx::Vector2d(0, 1);
scrollDeltaInZoomedViewport = ToFlooredVector2d(gfx::ScaleVector2d(scrollDelta, m_hostImpl->totalPageScaleFactorForTesting()));
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDeltaInZoomedViewport);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDeltaInZoomedViewport);
m_hostImpl->scrollEnd();
drawOneFrame();
@@ -4761,7 +4762,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportAndScrollBoundaryTest(const floa
gfx::Vector2d expectedMaxScroll(m_hostImpl->rootLayer()->maxScrollOffset());
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDeltaInZoomedViewport);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDeltaInZoomedViewport);
m_hostImpl->scrollEnd();
drawOneFrame();
@@ -4781,7 +4782,7 @@ void LayerTreeHostImplTest::pinchZoomPanViewportAndScrollBoundaryTest(const floa
scrollDeltaInZoomedViewport = ToFlooredVector2d(gfx::ScaleVector2d(scrollDelta, m_hostImpl->totalPageScaleFactorForTesting()));
expectedScrollDelta += gfx::Vector2d(0, 4); // This component gets handled by document scroll.
EXPECT_EQ(InputHandlerClient::ScrollStarted, m_hostImpl->scrollBegin(gfx::Point(0, 0), InputHandlerClient::Gesture));
- m_hostImpl->scrollBy(gfx::Point(), scrollDeltaInZoomedViewport);
+ m_hostImpl->scrollBy(0, gfx::Point(), scrollDeltaInZoomedViewport);
m_hostImpl->scrollEnd();
drawOneFrame();
« no previous file with comments | « cc/layer_tree_host_impl.cc ('k') | cc/layer_tree_host_unittest_scroll.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698