Closed Bug 1760227 Opened 3 years ago Closed 3 years ago

[wpt-sync] Sync PR 33225 - [block-in-inline] Fix hit-testing when block-in-inline in a culled inline

Categories

(Core :: CSS Parsing and Computation, task, P4)

task

Tracking

()

RESOLVED FIXED
100 Branch
Tracking Status
firefox100 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 33225 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/33225
Details from upstream follow.

Koji Ishii <kojii@chromium.org> wrote:

[block-in-inline] Fix hit-testing when block-in-inline in a culled inline

This is a follow up to r975579 crrev.com/c/3489020.

|NGBoxFragmentPainter::HitTestAllPhases| runs hit-testing in
phases:

  1. Try kHitTestForeground.
  2. If the result is none, try kHitTestFloat.
  3. If the result is none, try kHitTestChildBlockBackgrounds.

r975579 crrev.com/c/3489020 fixed hit-testing block
backgrounds of block-in-inline by honoring the phases.
However, when block-in-inline appears inside a culled inline,
the culled inline logic consider the block-in-inline is a part
of the culled inline. This computes the culled inline as a hit
in kHitTestForeground, therefore we don't try lower phases
of the painting order.

This patch changes |LayoutInline::HitTestCulledInline| to
ignore block-in-inline. By not hitting block-in-inline in the
inline kHitTestForeground phase, the hit-testing falls back
to kHitTestFloat and kHitTestChildBlockBackgrounds phases.

Bug: 1307110
Change-Id: I567c6c9b692c68ade8fb38f87c6c316930712746
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3529307
Reviewed-by: Kent Tamura \<tkent@chromium.org>
Commit-Queue: Koji Ishii \<kojii@chromium.org>
Cr-Commit-Position: refs/heads/main@{#982110}

Component: web-platform-tests → CSS Parsing and Computation
Product: Testing → Core

CI Results

Ran 12 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 1 tests and 1 subtests

Status Summary

Firefox

OK : 1
PASS: 1

Chrome

OK : 1
FAIL: 1

Safari

OK : 1
PASS: 1

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/9921e5ee4548 [wpt PR 33225] - [block-in-inline] Fix hit-testing when block-in-inline in a culled inline, a=testonly
Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/7e42a5e6cc99 [wpt PR 33225] - [block-in-inline] Fix hit-testing when block-in-inline in a culled inline, a=testonly
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 100 Branch
You need to log in before you can comment on or make changes to this bug.