| Index: Source/platform/scroll/ScrollView.cpp
|
| diff --git a/Source/platform/scroll/ScrollView.cpp b/Source/platform/scroll/ScrollView.cpp
|
| index 56bc53593a29dea66d28b8b11cab74951a4a420a..ba3958575ade7bf08a1a9fe60493947931dc976b 100644
|
| --- a/Source/platform/scroll/ScrollView.cpp
|
| +++ b/Source/platform/scroll/ScrollView.cpp
|
| @@ -279,14 +279,17 @@ void ScrollView::scrollTo(const IntSize& newOffset)
|
| scrollContents(scrollDelta);
|
| }
|
|
|
| -void ScrollView::setScrollPosition(const IntPoint& scrollPoint)
|
| +void ScrollView::setScrollPosition(const IntPoint& scrollPoint, ScrollBehavior scrollBehavior)
|
| {
|
| IntPoint newScrollPosition = adjustScrollPositionWithinRange(scrollPoint);
|
|
|
| if (newScrollPosition == scrollPosition())
|
| return;
|
|
|
| - updateScrollbars(IntSize(newScrollPosition.x(), newScrollPosition.y()));
|
| + if (scrollBehavior == ScrollBehaviorInstant)
|
| + updateScrollbars(IntSize(newScrollPosition.x(), newScrollPosition.y()));
|
| + else
|
| + ScrollableArea::programmaticallyScrollSmoothlyToOffset(newScrollPosition);
|
| }
|
|
|
| bool ScrollView::scroll(ScrollDirection direction, ScrollGranularity granularity)
|
|
|