Containing block size-dependent absolutely positioned block doesn't resize when content changes and scrollbar appears
Reported by
lo...@yandex-team.ru,
Nov 28 2016
|
||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.116 YaBrowser/16.10.0.2309 Safari/537.36 Example URL: https://jsfiddle.net/xt9js57a/1/ Steps to reproduce the problem: 1. Open https://jsfiddle.net/xt9js57a/1/ 2. Click twice on "click" What is the expected behavior? What went wrong? Visual bug Does it occur on multiple sites: Yes Is it a problem with a plugin? No Did this work before? N/A Does this work in other browsers? N/A Chrome version: 53.0.2785.116 Channel: stable OS Version: OS X 10.11.6 Flash Version: Shockwave Flash 24.0 r0
,
Dec 2 2016
,
Dec 2 2016
This has to do with the PaintLayerScrollableArea::FreezeScrollbarsScope mechanism in LayoutBlockFlow::layoutBlockFlow(). We fail to detect the height change, because we trigger a re-layout due to the new scrollbar, and in the second layout pass, height doesn't change, so we won't lay out the absolutely positioned descendants. I have a patch in the works that refactors the code in layoutBlock() and layoutBlockFlow(), which also happens to fix this bug.
,
Dec 5 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/9d96126f67850daf3c07586dc09fa334d592529c commit 9d96126f67850daf3c07586dc09fa334d592529c Author: mstensho <mstensho@opera.com> Date: Mon Dec 05 21:31:06 2016 Refactor layoutBlock() and layoutBlockFlow(). Happens to fix bugs. Move what only needs to be done once into layoutBlock(). Rename layoutBlockFlow() to layoutChildren(). Establish LayoutState once, and compare with the actual previous height to properly detect height changes. This fixes two issues with the PaintLayerScrollableArea::FreezeScrollbarsScope mechanism. Tests added. 1. We used to push LayoutState for the same object twice when freezing scrollbars, which confused the fragmentation machinery. 2. We failed to detect height changes when freezing scrollbars, because we were unable to compare against the original height (we compared against the height we had when entering the second layout pass, rather than comparing against the one we had when entering the first layout pass). We might therefore end up skipping necessary re-layout of absolutely positioned descendants. BUG= 669039 , 670660 Review-Url: https://codereview.chromium.org/2553833002 Cr-Commit-Position: refs/heads/master@{#436414} [add] https://crrev.com/9d96126f67850daf3c07586dc09fa334d592529c/third_party/WebKit/LayoutTests/fast/block/shrink-to-fit-with-height-stretched-abspos-and-auto-scrollbar-sibling.html [add] https://crrev.com/9d96126f67850daf3c07586dc09fa334d592529c/third_party/WebKit/LayoutTests/fragmentation/auto-scrollbar-shrink-to-fit.html [modify] https://crrev.com/9d96126f67850daf3c07586dc09fa334d592529c/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp [modify] https://crrev.com/9d96126f67850daf3c07586dc09fa334d592529c/third_party/WebKit/Source/core/layout/LayoutBlockFlow.h
,
Dec 5 2016
,
Feb 13 2017
|
||||
►
Sign in to add a comment |
||||
Comment 1 by rbyers@chromium.org
, Nov 28 2016Labels: -OS-Mac Hotlist-Interop OS-All
Status: Untriaged (was: Unconfirmed)
Summary: ::before pseudo element doesn't resize (was: Popup height bug)