Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(721)

Unified Diff: Source/core/dom/Element.cpp

Issue 14846002: Implement the Custom Elements :unresolved pseudoclass (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Adds a test and fixes style sharing. Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« Source/core/dom/CustomElementRegistry.h ('K') | « Source/core/dom/Element.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Element.cpp
diff --git a/Source/core/dom/Element.cpp b/Source/core/dom/Element.cpp
index f18ac2b05375b96c045b293df9af459255907fc3..ec7f353117253b0be46c7b06553960d1e3163c44 100644
--- a/Source/core/dom/Element.cpp
+++ b/Source/core/dom/Element.cpp
@@ -213,6 +213,10 @@ Element::~Element()
data->clearShadow();
}
+ if (isCustomElement() && document() && document()->registry()) {
+ document()->registry()->customElementWasDestroyed(this);
+ }
+
if (hasSyntheticAttrChildNodes())
detachAllAttrNodesFromElement();
@@ -2202,6 +2206,11 @@ bool Element::isInCanvasSubtree() const
return hasRareData() && elementRareData()->isInCanvasSubtree();
}
+bool Element::isUnresolvedCustomElement()
+{
+ return isCustomElement() && document()->registry()->isUnresolved(this);
+}
+
AtomicString Element::computeInheritedLanguage() const
{
const Node* n = this;
« Source/core/dom/CustomElementRegistry.h ('K') | « Source/core/dom/Element.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698