Fix position:-webkit-sticky behavior when zoomed
https://bugs.webkit.org/show_bug.cgi?id=105251
Reviewed by Dean Jackson.
Source/WebCore:
Position sticky elements were misplaced when stickily-constrained, under zooming.
The cause was that some of the functions used to compute sticky position
took page scale into account, and some did not.
Fix by using localToContainerQuad(..., view()) to compute RenderView-relative
quads, which avoids page scale, so all the constraints math is done ignoring
page scale. This also requires that we compute a scale-free viewport rect
in stickyPositionOffset().
Test: fast/css/sticky/sticky-top-zoomed.html
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::computeStickyPositionConstraints):
(WebCore::RenderBoxModelObject::stickyPositionOffset):
LayoutTests:
Ref test for sticky elements in a zoomed page.
This test is marked as failing for WK1, because scrollbars always show on
zoomed pages and cannot be hidden there.
* fast/css/sticky/sticky-top-zoomed-expected.html: Added.
* fast/css/sticky/sticky-top-zoomed.html: Added.
* platform/mac-wk2/TestExpectations:
* platform/mac/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@138036
268f45cc-cd09-0410-ab3c-
d52691b4dbfc