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

Unified Diff: third_party/WebKit/Source/core/dom/Node.cpp

Issue 2257053003: Fix a crash when pseudo elements are used for a shadow host (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update Created 4 years, 4 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
« no previous file with comments | « third_party/WebKit/Source/core/dom/LayoutTreeBuilderTraversal.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/dom/Node.cpp
diff --git a/third_party/WebKit/Source/core/dom/Node.cpp b/third_party/WebKit/Source/core/dom/Node.cpp
index a834c8b5463ed24fa606b1d574f35798798572cf..237ae2a7914b61dcbfe6a2fdc4f899929e799bad 100644
--- a/third_party/WebKit/Source/core/dom/Node.cpp
+++ b/third_party/WebKit/Source/core/dom/Node.cpp
@@ -970,6 +970,7 @@ bool Node::isStyledElement() const
bool Node::canParticipateInFlatTree() const
{
+ // TODO(hayato): Return false for pseudo elements.
return !isShadowRoot() && !isSlotOrActiveInsertionPoint();
}
@@ -2184,6 +2185,7 @@ StaticNodeList* Node::getDestinationInsertionPoints()
HTMLSlotElement* Node::assignedSlot() const
{
+ DCHECK(!isPseudoElement());
if (ShadowRoot* root = v1ShadowRootOfParent())
return root->ensureSlotAssignment().findSlot(*this);
return nullptr;
« no previous file with comments | « third_party/WebKit/Source/core/dom/LayoutTreeBuilderTraversal.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698