| Index: cc/layer_tree_host_impl.cc
|
| diff --git a/cc/layer_tree_host_impl.cc b/cc/layer_tree_host_impl.cc
|
| index cdd69954b01b547a5a39db34fec852bbaf3588ce..a12a4e84a6c13fe2c14ee3d458c7840d2cb99b7a 100644
|
| --- a/cc/layer_tree_host_impl.cc
|
| +++ b/cc/layer_tree_host_impl.cc
|
| @@ -1012,7 +1012,7 @@ void LayerTreeHostImpl::updateMaxScrollOffset()
|
|
|
| // The viewport may be larger than the contents in some cases, such as
|
| // having a vertical scrollbar but no horizontal overflow.
|
| - maxScroll = ClampFromBelow(maxScroll, gfx::Vector2dF());
|
| + maxScroll.ClampToMin(gfx::Vector2dF());
|
|
|
| m_rootScrollLayerImpl->setMaxScrollOffset(gfx::ToFlooredVector2d(maxScroll));
|
| }
|
| @@ -1300,8 +1300,8 @@ void LayerTreeHostImpl::computePinchZoomDeltas(ScrollAndScaleSet* scrollInfo)
|
| gfx::Vector2dF scrollEnd = scrollBegin + anchorOffset;
|
| scrollEnd.Scale(m_pinchZoomViewport.minPageScaleFactor() / scaleBegin);
|
| scrollEnd -= anchorOffset;
|
| - scrollEnd = ClampFromAbove(scrollEnd, BottomRight(gfx::RectF(scaledContentsSize)) - BottomRight(gfx::Rect(m_deviceViewportSize)));
|
| - scrollEnd = ClampFromBelow(scrollEnd, gfx::Vector2d());
|
| + scrollEnd.ClampToMax(BottomRight(gfx::RectF(scaledContentsSize)) - BottomRight(gfx::Rect(m_deviceViewportSize)));
|
| + scrollEnd.ClampToMin(gfx::Vector2d());
|
| scrollEnd.Scale(1 / pageScaleDeltaToSend);
|
| scrollEnd.Scale(m_deviceScaleFactor);
|
|
|
|
|