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

Unified Diff: third_party/WebKit/Source/platform/scroll/ScrollAnimator.cpp

Issue 1801753002: First programmatic smooth scroll should run on the compositor if it can (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix bot compile error Created 4 years, 9 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/ScrollAnimator.cpp
diff --git a/third_party/WebKit/Source/platform/scroll/ScrollAnimator.cpp b/third_party/WebKit/Source/platform/scroll/ScrollAnimator.cpp
index 7c5380a78842495676e97c6fc9c01f43bf53fda6..ab02ae1b29876a54f6bf9a60375de1bec3c4b0fc 100644
--- a/third_party/WebKit/Source/platform/scroll/ScrollAnimator.cpp
+++ b/third_party/WebKit/Source/platform/scroll/ScrollAnimator.cpp
@@ -279,6 +279,9 @@ void ScrollAnimator::updateCompositorAnimations()
if (m_runState == RunState::WaitingToSendToCompositor
|| m_runState == RunState::RunningOnCompositorButNeedsUpdate) {
+ if (!m_compositorAnimationAttachedToLayerId)
+ reattachCompositorPlayerIfNeeded(getScrollableArea()->compositorAnimationTimeline());
+
if (m_runState == RunState::RunningOnCompositorButNeedsUpdate) {
// Abort the running animation before a new one with an updated
// target is added.

Powered by Google App Engine
This is Rietveld 408576698