Closed Bug 1478304 Opened Last year Closed Last year

Can't scroll when click/hover a sticky element in a parent with transform


(Core :: Panning and Zooming, defect, P3)

63 Branch



Tracking Status
firefox61 --- wontfix
firefox62 --- wontfix
firefox63 --- wontfix
firefox64 --- fixed


(Reporter: bad__boss, Assigned: botond)


(Whiteboard: [gfx-noted])


(3 files)

Attached file sticky_scroll.html
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:63.0) Gecko/20100101 Firefox/63.0
Build ID: 20180724223402

Steps to reproduce:

Try to scroll(mouse wheel) when hovering or clicking a sticky element

scroll container
└ css:transform:- element
   └ css:position:sticky element

Actual results:

Can't scroll

Expected results:

Can scroll
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:63.0) Gecko/20100101 Firefox/63.0
Build ID: 20180726001822

I can reproduce the issue on Release 61.0.1, Beta 62.0b11 and latest Nightly 63.0a1(2018-07-26) on Windows 10 x64 and Mac OS X 10.12.
Component: General → CSS Parsing and Computation
Ever confirmed: true
OS: Unspecified → All
Hardware: Unspecified → All
WFM with webrender, which means that this is likely a graphics bug instead.
Component: CSS Parsing and Computation → Graphics
Thanks for the testcase! This does seem like an APZ bug of some sort.
Component: Graphics → Panning and Zooming
Priority: -- → P3
Whiteboard: [gfx-noted]
What's happening here is:

  * Layout code calls Layer::SetFixedPositionData() for both fixed 
    and sticky layers. This is necessary because at least some of
    the fixed position data (the anchor and the sides) are used
    by AsyncCompositionManager for both fixed and sticky layers.

  * As a result, Layer::GetFixedPositionScrollContainerId() returns
    non-NULL_SCROLL_ID for both fixed and sticky layers.

  * When building the hit-testing tree, however, APZCTreeManager
    interprets Layer::GetFixedPositionScrollContainerId() returning
    non-NULL_SCROLL_ID as meaning the layer is fixed, and marks
    the corresponding hit-testing node as fixed, which in turn
    causes events that hit the node to be redirected to the
    document's RSF.
Assignee: nobody → botond
Depends on D9327
Pushed by
Ensure Layer::GetFixedPositionScrollContainerId() returns NULL_SCROLL_ID for layers that are not fixed. r=kats
Add a mochitest. r=kats
Closed: Last year
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
You need to log in before you can comment on or make changes to this bug.