Changeset 290548 in webkit


Ignore:
Timestamp:
Feb 26, 2022 10:43:07 AM (5 months ago)
Author:
Simon Fraser
Message:

No animation when scroll snap scroller is navigated with the keyboard
https://bugs.webkit.org/show_bug.cgi?id=236244

Reviewed by Tim Horton.

Source/WebCore:

Keyboard-driven scrolls in overflow didn't animate, simply because scrollAnimatorEnabled()
wasn't implemented for RenderLayerScrollableArea.

I could not figure out a reliable way to test that we animated the scroll.

  • rendering/RenderLayerScrollableArea.cpp:

(WebCore::RenderLayerScrollableArea::scrollAnimatorEnabled const):

  • rendering/RenderLayerScrollableArea.h:

LayoutTests:

Turn off the scroll animator for these tests that assume that scrolling is instantaneous.

  • css3/scroll-snap/scroll-padding-overflow-paging.html:
  • fast/events/wheelevent-in-scrolling-div.html:
  • tiled-drawing/scrolling/scroll-snap/scroll-snap-proximity-overflow-rtl-with-keyboard.html:
Location:
trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r290546 r290548  
     12022-02-26  Simon Fraser  <simon.fraser@apple.com>
     2
     3        No animation when scroll snap scroller is navigated with the keyboard
     4        https://bugs.webkit.org/show_bug.cgi?id=236244
     5
     6        Reviewed by Tim Horton.
     7
     8        Turn off the scroll animator for these tests that assume that scrolling is instantaneous.
     9
     10        * css3/scroll-snap/scroll-padding-overflow-paging.html:
     11        * fast/events/wheelevent-in-scrolling-div.html:
     12        * tiled-drawing/scrolling/scroll-snap/scroll-snap-proximity-overflow-rtl-with-keyboard.html:
     13
    1142022-02-26  Youenn Fablet  <youenn@apple.com>
    215
  • trunk/LayoutTests/css3/scroll-snap/scroll-padding-overflow-paging.html

    r271788 r290548  
    1 <!DOCTYPE html>
     1<!DOCTYPE html> <!-- webkit-test-runner [ ScrollAnimatorEnabled=false ] -->
    22<html>
    33    <head>
  • trunk/LayoutTests/fast/events/wheelevent-in-scrolling-div.html

    r212321 r290548  
     1<!DOCTYPE html> <!-- webkit-test-runner [ ScrollAnimatorEnabled=false ] -->
    12<html>
    23    <head>
  • trunk/LayoutTests/tiled-drawing/scrolling/scroll-snap/scroll-snap-proximity-overflow-rtl-with-keyboard.html

    r270838 r290548  
    1 <!DOCTYPE HTML>
     1<!DOCTYPE html> <!-- webkit-test-runner [ ScrollAnimatorEnabled=false ] -->
    22<html>
    33    <head>
  • trunk/Source/WebCore/ChangeLog

    r290545 r290548  
     12022-02-26  Simon Fraser  <simon.fraser@apple.com>
     2
     3        No animation when scroll snap scroller is navigated with the keyboard
     4        https://bugs.webkit.org/show_bug.cgi?id=236244
     5
     6        Reviewed by Tim Horton.
     7
     8        Keyboard-driven scrolls in overflow didn't animate, simply because scrollAnimatorEnabled()
     9        wasn't implemented for RenderLayerScrollableArea.
     10
     11        I could not figure out a reliable way to test that we animated the scroll.
     12
     13        * rendering/RenderLayerScrollableArea.cpp:
     14        (WebCore::RenderLayerScrollableArea::scrollAnimatorEnabled const):
     15        * rendering/RenderLayerScrollableArea.h:
     16
    1172022-02-25  Simon Fraser  <simon.fraser@apple.com>
    218
  • trunk/Source/WebCore/rendering/RenderLayerScrollableArea.cpp

    r288008 r290548  
    15431543}
    15441544
     1545bool RenderLayerScrollableArea::scrollAnimatorEnabled() const
     1546{
     1547    return m_layer.page().settings().scrollAnimatorEnabled();
     1548}
     1549
    15451550void RenderLayerScrollableArea::paintOverlayScrollbars(GraphicsContext& context, const LayoutRect& damageRect, OptionSet<PaintBehavior> paintBehavior, RenderObject* subtreePaintRoot)
    15461551{
  • trunk/Source/WebCore/rendering/RenderLayerScrollableArea.h

    r288008 r290548  
    194194    bool forceUpdateScrollbarsOnMainThreadForPerformanceTesting() const final;
    195195    bool isScrollSnapInProgress() const final;
     196    bool scrollAnimatorEnabled() const final;
    196197    bool mockScrollbarsControllerEnabled() const final;
    197198    void logMockScrollbarsControllerMessage(const String&) const final;
Note: See TracChangeset for help on using the changeset viewer.