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

Unified Diff: third_party/WebKit/Source/platform/scroll/ProgrammaticScrollAnimator.h

Issue 2650343008: Implement Element.scrollIntoView for scroll-behavior: smooth. (Closed)
Patch Set: Fixed nits. Created 3 years, 6 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
Index: third_party/WebKit/Source/platform/scroll/ProgrammaticScrollAnimator.h
diff --git a/third_party/WebKit/Source/platform/scroll/ProgrammaticScrollAnimator.h b/third_party/WebKit/Source/platform/scroll/ProgrammaticScrollAnimator.h
index f8a365c32b9584f2e5efabc5ac292e62cd27e0b4..8f1240fa127a5939d3dde87a419d3a1437a9c4f6 100644
--- a/third_party/WebKit/Source/platform/scroll/ProgrammaticScrollAnimator.h
+++ b/third_party/WebKit/Source/platform/scroll/ProgrammaticScrollAnimator.h
@@ -30,7 +30,8 @@ class ProgrammaticScrollAnimator : public ScrollAnimatorCompositorCoordinator {
virtual ~ProgrammaticScrollAnimator();
void ScrollToOffsetWithoutAnimation(const ScrollOffset&);
- void AnimateToOffset(const ScrollOffset&);
+ void AnimateToOffset(const ScrollOffset&,
+ bool sequenced_for_smooth_scroll = false);
// ScrollAnimatorCompositorCoordinator implementation.
void ResetAnimationState() override;
@@ -52,11 +53,13 @@ class ProgrammaticScrollAnimator : public ScrollAnimatorCompositorCoordinator {
explicit ProgrammaticScrollAnimator(ScrollableArea*);
void NotifyOffsetChanged(const ScrollOffset&);
+ void AnimationFinished();
Member<ScrollableArea> scrollable_area_;
std::unique_ptr<CompositorScrollOffsetAnimationCurve> animation_curve_;
ScrollOffset target_offset_;
double start_time_;
+ bool sequenced_for_smooth_scroll_;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698