Closed Bug 1039623 Opened 7 years ago Closed 7 years ago
Scroll parents in UI Tests -> Scrollbar are incorrect
STR: 1. Run the "UI Tests" app on B2G. 2. Choose the "Scroll bar" test. Observe that the main area of the page (everything except the header) is scrollable, as are the three boxes on the page. There is a clear parent->child relationship between the former and the latter, and we would expect the scroll parent of the boxes to the be the main area (and therefore overscroll to be handed off from the boxes to the main area). However, this is not what happens. The scroll parent of both the main area and the boxes is the root APZC of the app, which is not scrollable. As a result, overscroll on the boxes is not handed off to anything and the boxes themselves overscroll.
Where can I find the source for the scroll bar test page?
(In reply to Timothy Nikkel (:tn) from comment #1) > Where can I find the source for the scroll bar test page? https://github.com/mozilla-b2g/gaia/blob/master/dev_apps/uitest/tests_html/UI/scrollbar.html
I should mention that the layers in question *do* have a parent->child relationship in the layer tree, it's just the scroll parents that are wrong.
Best I can tell is that scrollbar.html is in a non-remote iframe and it should be setting the scroll parent id here http://mxr.mozilla.org/mozilla-central/source/layout/generic/nsSubDocumentFrame.cpp#467 for its root scroll frame. So either one of the things I just said is wrong or the problem is somewhere else.
(In reply to Timothy Nikkel (:tn) from comment #4) > Best I can tell is that scrollbar.html is in a non-remote iframe and it > should be setting the scroll parent id here > http://mxr.mozilla.org/mozilla-central/source/layout/generic/ > nsSubDocumentFrame.cpp#467 for its root scroll frame. So either one of the > things I just said is wrong or the problem is somewhere else. Looks like subdocRootFrame->GetContent() is nullptr there.
Ah! subdocRootFrame is the wrong frame to be using there. We should be using the root scroll frame.
Using the root scroll frame does fix the problem.
Assignee: nobody → botond
Attachment #8457660 - Flags: review?(tnikkel)
Attachment #8457660 - Flags: review?(tnikkel) → review+
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla33
You need to log in before you can comment on or make changes to this bug.