Skip to content
Snippets Groups Projects
Forked from The Tor Project / Applications / Tor Browser
Source project has a limited visibility.
  • Hiroyuki Ikezoe's avatar
    a457a5cf
    Bug 1766805 - Introduce intended direction and intended end position concepts. r=botond · a457a5cf
    Hiroyuki Ikezoe authored
    The scroll snap spec defines the concepts [1]. There are three type of scroll
    operations. 1) intended end position, 2) intended direction and end position
    and 3) intended direction.
    
    Basically our existing ScrollUnits types correspond;
    
    1) DEVICE_PIXELS, WHOLE => intended end position
    2) PAGES => intended direction and end position
    3) LINES => intended direction
    
    There are two exceptions in the `intended direction and end position` case,
    scrollBy() and fling gestures (on Linux). They were defined as scroll operations
    with DEVICE_PIXELS unit, but the spec cleary says they are `intended direction
    and end position` operations.
    
    Note that we will also use this information for scroll-snap-stop property since
    the properly will only have effects on both 2) and 3) cases.
    
    [1] https://drafts.csswg.org/css-scroll-snap/#scroll-types
    
    Depends on D145190
    
    Differential Revision: https://phabricator.services.mozilla.com/D145191
    a457a5cf
    History
    Bug 1766805 - Introduce intended direction and intended end position concepts. r=botond
    Hiroyuki Ikezoe authored
    The scroll snap spec defines the concepts [1]. There are three type of scroll
    operations. 1) intended end position, 2) intended direction and end position
    and 3) intended direction.
    
    Basically our existing ScrollUnits types correspond;
    
    1) DEVICE_PIXELS, WHOLE => intended end position
    2) PAGES => intended direction and end position
    3) LINES => intended direction
    
    There are two exceptions in the `intended direction and end position` case,
    scrollBy() and fling gestures (on Linux). They were defined as scroll operations
    with DEVICE_PIXELS unit, but the spec cleary says they are `intended direction
    and end position` operations.
    
    Note that we will also use this information for scroll-snap-stop property since
    the properly will only have effects on both 2) and 3) cases.
    
    [1] https://drafts.csswg.org/css-scroll-snap/#scroll-types
    
    Depends on D145190
    
    Differential Revision: https://phabricator.services.mozilla.com/D145191