Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: aaa2528fde20bb2338e6ef09616e33b7ecdafb0b
https://github.com/WebKit/WebKit/commit/aaa2528fde20bb2338e6ef09616e33b7ecdafb0b
Author: Antti Koivisto <[email protected]>
Date: 2022-11-17 (Thu, 17 Nov 2022)
Changed paths:
M
LayoutTests/editing/pasteboard/copy-paste-across-shadow-boundaries-4-expected.txt
R
LayoutTests/platform/mac-wk2/imported/w3c/web-platform-tests/inert/inert-node-is-unfocusable-expected.txt
M Source/WebCore/dom/Element.cpp
M Source/WebCore/dom/Element.h
M Source/WebCore/dom/Node.cpp
M Source/WebCore/editing/AppendNodeCommand.cpp
Log Message:
-----------
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
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes