WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
Patch
bug-214291-20210502122155.patch (text/plain), 10.13 KB, created by
Rob Buis
on 2021-05-02 03:21:57 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Rob Buis
Created:
2021-05-02 03:21:57 PDT
Size:
10.13 KB
patch
obsolete
>Subversion Revision: 276846 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index c11840e43bb3ec42bd4204bae29f0ca6a4943b94..dd3ced1555f6531327603c5aae6d1402c98a37fa 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,15 @@ >+2021-05-01 Rob Buis <rbuis@igalia.com> >+ >+ [css-writing-modes] New failures on WPT ref-tests after updating WPT import >+ https://bugs.webkit.org/show_bug.cgi?id=214291 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ WIP. >+ >+ * dom/Element.cpp: >+ (WebCore::Element::computedStyle): >+ > 2021-04-30 Youenn Fablet <youenn@apple.com> > > REGRESSION (iOS 14.5): PWA's / Home Screen Apps with Service Workers intermittenly fail to open offline >diff --git a/Source/WebCore/css/CSSComputedStyleDeclaration.cpp b/Source/WebCore/css/CSSComputedStyleDeclaration.cpp >index bac52984102eb0045dc6535ae68e68b9b4668d03..6486a01b85f0d12c928e6936bb6dfdb0ecc35242 100644 >--- a/Source/WebCore/css/CSSComputedStyleDeclaration.cpp >+++ b/Source/WebCore/css/CSSComputedStyleDeclaration.cpp >@@ -2328,7 +2328,7 @@ static inline const RenderStyle* computeRenderStyleForProperty(Element& element, > return ownedStyle.get(); > } > >- return element.computedStyle(element.isPseudoElement() ? PseudoId::None : pseudoElementSpecifier); >+ return element.computedStyle(element.isPseudoElement() ? PseudoId::None : pseudoElementSpecifier, Node::AllowRenderStyle::No); > } > > static Ref<CSSValue> shapePropertyValue(const RenderStyle& style, const ShapeValue* shapeValue) >diff --git a/Source/WebCore/dom/Element.cpp b/Source/WebCore/dom/Element.cpp >index 0efed523c0bd07741cb1beaeda485c065a7156eb..aa121b0c1acfb6872d5a2fbbb6acbb605d6d1870 100644 >--- a/Source/WebCore/dom/Element.cpp >+++ b/Source/WebCore/dom/Element.cpp >@@ -3484,7 +3484,7 @@ const RenderStyle& Element::resolvePseudoElementStyle(PseudoId pseudoElementSpec > return *computedStyle; > } > >-const RenderStyle* Element::computedStyle(PseudoId pseudoElementSpecifier) >+const RenderStyle* Element::computedStyle(PseudoId pseudoElementSpecifier, AllowRenderStyle allowRenderStyle) > { > if (!isConnected()) > return nullptr; >@@ -3492,7 +3492,14 @@ const RenderStyle* Element::computedStyle(PseudoId pseudoElementSpecifier) > if (PseudoElement* pseudoElement = beforeOrAfterPseudoElement(*this, pseudoElementSpecifier)) > return pseudoElement->computedStyle(); > >- auto* style = existingComputedStyle(); >+ const RenderStyle* style = nullptr; >+ if (allowRenderStyle == AllowRenderStyle::No && document().documentElement() == this) { >+ if (hasRareData()) >+ style = elementRareData()->computedStyle(); >+ else >+ setNodeFlag(NodeFlag::IsComputedStyleInvalidFlag); >+ } else >+ style = existingComputedStyle(); > if (!style) > style = resolveComputedStyle(); > >diff --git a/Source/WebCore/dom/Element.h b/Source/WebCore/dom/Element.h >index c4aa6683cbfa3ad7558e5508d8bb4d82feb6d473..be7747dc2707e81546aa4426e75032677ce28511 100644 >--- a/Source/WebCore/dom/Element.h >+++ b/Source/WebCore/dom/Element.h >@@ -351,7 +351,7 @@ public: > WEBCORE_EXPORT ExceptionOr<void> insertAdjacentHTML(const String& where, const String& html); > WEBCORE_EXPORT ExceptionOr<void> insertAdjacentText(const String& where, const String& text); > >- const RenderStyle* computedStyle(PseudoId = PseudoId::None) override; >+ const RenderStyle* computedStyle(PseudoId = PseudoId::None, AllowRenderStyle = AllowRenderStyle::Yes) override; > > bool needsStyleInvalidation() const; > >diff --git a/Source/WebCore/dom/Node.cpp b/Source/WebCore/dom/Node.cpp >index 78f0e995a6691abd6adf79fa92f09296a8b232e3..fb0181882d86bed1901db2d1f82a285bcc908e5f 100644 >--- a/Source/WebCore/dom/Node.cpp >+++ b/Source/WebCore/dom/Node.cpp >@@ -1111,12 +1111,12 @@ Node* Node::pseudoAwareLastChild() const > return lastChild(); > } > >-const RenderStyle* Node::computedStyle(PseudoId pseudoElementSpecifier) >+const RenderStyle* Node::computedStyle(PseudoId pseudoElementSpecifier, AllowRenderStyle allowRenderStyle) > { > auto* composedParent = composedTreeAncestors(*this).first(); > if (!composedParent) > return nullptr; >- return composedParent->computedStyle(pseudoElementSpecifier); >+ return composedParent->computedStyle(pseudoElementSpecifier, allowRenderStyle); > } > > // FIXME: Shouldn't these functions be in the editing code? Code that asks questions about HTML in the core DOM class >diff --git a/Source/WebCore/dom/Node.h b/Source/WebCore/dom/Node.h >index dda6f8ac2acae9777aae9487e76c7bb98f95f16c..48995e307215771823a6e3c691fae53a59d83344 100644 >--- a/Source/WebCore/dom/Node.h >+++ b/Source/WebCore/dom/Node.h >@@ -408,7 +408,8 @@ public: > // Wrapper for nodes that don't have a renderer, but still cache the style (like HTMLOptionElement). > const RenderStyle* renderStyle() const; > >- virtual const RenderStyle* computedStyle(PseudoId pseudoElementSpecifier = PseudoId::None); >+ enum class AllowRenderStyle { Yes, No }; >+ virtual const RenderStyle* computedStyle(PseudoId pseudoElementSpecifier = PseudoId::None, AllowRenderStyle = AllowRenderStyle::Yes); > > enum class InsertedIntoAncestorResult { > Done, >diff --git a/Source/WebCore/svg/SVGElement.cpp b/Source/WebCore/svg/SVGElement.cpp >index 5c2df2e8d958b9b4dc6d60aff41e7ce6d132cff6..30ef2463ea9f76fb9a9c9eafa562fbd20ed5cf3a 100644 >--- a/Source/WebCore/svg/SVGElement.cpp >+++ b/Source/WebCore/svg/SVGElement.cpp >@@ -614,7 +614,7 @@ void SVGElement::setUseOverrideComputedStyle(bool value) > m_svgRareData->setUseOverrideComputedStyle(value); > } > >-const RenderStyle* SVGElement::computedStyle(PseudoId pseudoElementSpecifier) >+const RenderStyle* SVGElement::computedStyle(PseudoId pseudoElementSpecifier, AllowRenderStyle) > { > if (!m_svgRareData || !m_svgRareData->useOverrideComputedStyle()) > return Element::computedStyle(pseudoElementSpecifier); >diff --git a/Source/WebCore/svg/SVGElement.h b/Source/WebCore/svg/SVGElement.h >index a6a4692eeb725af0aaf82172b80642bb8cb541c4..8fdf45964b5b2c13c6a10399cf890146e93fc7fd 100644 >--- a/Source/WebCore/svg/SVGElement.h >+++ b/Source/WebCore/svg/SVGElement.h >@@ -140,7 +140,7 @@ public: > RefPtr<SVGAttributeAnimator> createAnimator(const QualifiedName&, AnimationMode, CalcMode, bool isAccumulated, bool isAdditive); > void animatorWillBeDeleted(const QualifiedName&); > >- const RenderStyle* computedStyle(PseudoId = PseudoId::None) final; >+ const RenderStyle* computedStyle(PseudoId = PseudoId::None, AllowRenderStyle = AllowRenderStyle::Yes) final; > > // These are needed for the RenderTree, animation and DOM. > String className() const { return m_className->currentValue(); } >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index 7e52d190f20dcd29e16ec6f8f0ad6dfb6f32ae06..bd0a44fc617701621e155a9627a1f55589fe6753 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,12 @@ >+2021-05-01 Rob Buis <rbuis@igalia.com> >+ >+ [css-writing-modes] New failures on WPT ref-tests after updating WPT import >+ https://bugs.webkit.org/show_bug.cgi?id=214291 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * TestExpectations: >+ > 2021-04-30 Antti Koivisto <antti@apple.com> > > Share style resolvers between author shadow trees without style sheets >diff --git a/LayoutTests/imported/w3c/ChangeLog b/LayoutTests/imported/w3c/ChangeLog >index be5f6a0ccf6afa45e87b9e1a89dba6a9176ce765..5da4b4a7afd21684b88b9aa508b8cb56116cad72 100644 >--- a/LayoutTests/imported/w3c/ChangeLog >+++ b/LayoutTests/imported/w3c/ChangeLog >@@ -1,3 +1,12 @@ >+2021-05-01 Rob Buis <rbuis@igalia.com> >+ >+ [css-writing-modes] New failures on WPT ref-tests after updating WPT import >+ https://bugs.webkit.org/show_bug.cgi?id=214291 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * web-platform-tests/css/css-writing-modes/wm-propagation-body-computed-root-expected.txt: >+ > 2021-04-30 Oriol Brufau <obrufau@igalia.com> > > [css-logical] Fix logical shorthands with var() >diff --git a/LayoutTests/TestExpectations b/LayoutTests/TestExpectations >index 42e5b30b28e30de9cdcdeeaab3e8c60e683a3864..dcb33a0a880d7334fe13aa1c9fa7fddc54c0293a 100644 >--- a/LayoutTests/TestExpectations >+++ b/LayoutTests/TestExpectations >@@ -4100,8 +4100,6 @@ webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/srl-al > webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/tcy-white-space-processing-001.html [ ImageOnlyFailure ] > webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/text-orientation-initial.html [ ImageOnlyFailure ] > webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-001.html [ ImageOnlyFailure ] >-webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-032.html [ ImageOnlyFailure ] >-webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-033.html [ ImageOnlyFailure ] > webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-034.html [ ImageOnlyFailure ] > webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-035.html [ ImageOnlyFailure ] > webkit.org/b/214291 imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-036.html [ ImageOnlyFailure ] >diff --git a/LayoutTests/imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-computed-root-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-computed-root-expected.txt >index 750e2b9096a68960bf88a9e94dddf17f90f1ee83..a972405e9ec8147b7501288573b06f1107163e37 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-computed-root-expected.txt >+++ b/LayoutTests/imported/w3c/web-platform-tests/css/css-writing-modes/wm-propagation-body-computed-root-expected.txt >@@ -1,5 +1,5 @@ > > PASS Check computed writing-mode for body element. >-FAIL Check computed writing-mode for html root element. assert_not_equals: got disallowed value "vertical-lr" >+PASS Check computed writing-mode for html root element. > FAIL Check computed writing-mode for body element when style no longer applies. assert_not_equals: got disallowed value "vertical-lr" >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
ews-feeder
:
commit-queue-
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 214291
:
427508
|
427522
|
427524
|
427527
|
427532