Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
imported/w3c/web-platform-tests/inert/inert-node-is-unfocusable.html …
…is failing https://bugs.webkit.org/show_bug.cgi?id=247803 <rdar://problem/102367494> Reviewed by Alan Baradlay. Ancestors may have changes that need to be inherited to the descendants. We handle this correctly for the current chain but the ancestors invalidity bit gets cleared in the process. If computed style is later resolved for a sibling we fail to take this into account. * LayoutTests/platform/mac-wk2/imported/w3c/web-platform-tests/inert/inert-node-is-unfocusable-expected.txt: Removed. LayoutTests/editing/pasteboard/copy-paste-across-shadow-boundaries-4-expected.txt: The new results are equivalent. * Source/WebCore/dom/Element.cpp: (WebCore::Element::resolveComputedStyle): Fix by marking ancestor computed style explicitly invalid if the parent has an inherited style change. Also add an optimizations for the case where style is already valid. (WebCore::Element::computedStyle): (WebCore::Element::computedStyleForEditability): Add a version of computedStyle() that calls resolveComputedStyle unconditionally. This should really be done in all cases, not just for editability testing but that will be left as future work. * Source/WebCore/dom/Element.h: * Source/WebCore/dom/Node.cpp: (WebCore::Node::computeEditabilityWithStyle const): Use computedStyleForEditability(). (WebCore::Node::computedStyle): * Source/WebCore/editing/AppendNodeCommand.cpp: (WebCore::AppendNodeCommand::AppendNodeCommand): Remove hasEditableStyle assert. It is tested in apply() functions and no other commands has this assert. Canonical link: https://commits.webkit.org/256782@main
- Loading branch information
Showing
6 changed files
with
40 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 0 additions & 13 deletions
13
...form/mac-wk2/imported/w3c/web-platform-tests/inert/inert-node-is-unfocusable-expected.txt
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters