[LayoutNG] Hit-testing on block gets confused by subsequent inline-block in vertical-rl |
||
Issue descriptionIf there's an inline-block (or similar; input elements also have the same effect) after a block inside a vertical-rl writing-mode container, hit testing will be offset by the width of the inline-block. See the test case attached. Try hovering to the RIGHT of the blue block, and it will appear to be hovered. Discovered while attempting to enable NG for DETAILS/SUMMARY in the test html/details_summary/details-mouse-click.html
,
Jul 2
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/cb238dbf866deb301fad7b84ac67a2b593bc5330 commit cb238dbf866deb301fad7b84ac67a2b593bc5330 Author: Xiaocheng Hu <xiaochengh@chromium.org> Date: Mon Jul 02 21:03:37 2018 [LayoutNG] Cleanup and fix hit test fallback offset calculation Currently, LayoutNG hit test code uses FallbackAccumulatedOffset() to calculate the |accumulated_offset| parameter at two places: 1. When falling back to LayoutBox::HitTestAllPhases/NodeAtPoint 2. When falling back to LayoutInline::HitTestCulledInline However, the parameter actually has different semantics in the two legacy functions. This makes the function complicated and hard to modify. This patch breaks the function, which results in simplification at both fallback sites. Besides, it also fixes the offset calculation at the first site in 'vertical-rl' writing mode, making two layout tests pass. Bug: 855279 , 856730 Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_layout_ng;luci.chromium.try:linux_layout_tests_slimming_paint_v2;master.tryserver.blink:linux_trusty_blink_rel Change-Id: Iaa59cbfbb2396f2df7c1550fca45eb4ae84e3052 Reviewed-on: https://chromium-review.googlesource.com/1119639 Commit-Queue: Xiaocheng Hu <xiaochengh@chromium.org> Reviewed-by: Koji Ishii <kojii@chromium.org> Reviewed-by: Emil A Eklund <eae@chromium.org> Cr-Commit-Position: refs/heads/master@{#571994} [modify] https://crrev.com/cb238dbf866deb301fad7b84ac67a2b593bc5330/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG [modify] https://crrev.com/cb238dbf866deb301fad7b84ac67a2b593bc5330/third_party/WebKit/LayoutTests/TestExpectations [modify] https://crrev.com/cb238dbf866deb301fad7b84ac67a2b593bc5330/third_party/blink/renderer/core/paint/ng/ng_box_fragment_painter.cc
,
Jul 2
|
||
►
Sign in to add a comment |
||
Comment 1 by xiaoche...@chromium.org
, Jun 26 2018Status: Assigned (was: Available)