| Summary: | Clean up state maintenance around animated scrolls | ||||||
|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Simon Fraser (smfr) <simon.fraser> | ||||
| Component: | Scrolling | Assignee: | Simon Fraser (smfr) <simon.fraser> | ||||
| Status: | RESOLVED FIXED | ||||||
| Severity: | Normal | CC: | cathiechen, changseok, clord, cmarcelo, esprehn+autocc, ews-watchlist, fred.wang, glenn, jamesr, kondapallykalyan, luiz, mrobinson, pdr, simon.fraser, tonikitoo, webkit-bug-importer | ||||
| Priority: | P2 | Keywords: | InRadar | ||||
| Version: | WebKit Nightly Build | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Attachments: |
|
||||||
|
Description
Simon Fraser (smfr)
2021-10-06 21:28:55 PDT
Created attachment 440466 [details]
Patch
Comment on attachment 440466 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=440466&action=review Really glad to see this simplification. > Source/WebCore/platform/ScrollView.cpp:530 > + if ((!delegatesScrolling() || currentScrollType() == ScrollType::User) && scrollAnimationStatus() == ScrollAnimationStatus::NotAnimating && newScrollPosition == this->scrollPosition()) I wonder about the combination of testing `scrollAnimationStatus() == ScrollAnimationStatus::NotAnimating` and the call to `scrollAnimator().cancelAnimations();` above. Perhaps `scrollAnimationStatus() == ScrollAnimationStatus::NotAnimating` is always true? Comment on attachment 440466 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=440466&action=review >> Source/WebCore/platform/ScrollView.cpp:530 >> + if ((!delegatesScrolling() || currentScrollType() == ScrollType::User) && scrollAnimationStatus() == ScrollAnimationStatus::NotAnimating && newScrollPosition == this->scrollPosition()) > > I wonder about the combination of testing `scrollAnimationStatus() == ScrollAnimationStatus::NotAnimating` and the call to `scrollAnimator().cancelAnimations();` above. Perhaps `scrollAnimationStatus() == ScrollAnimationStatus::NotAnimating` is always true? I think you're right. |