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

Unified Diff: sky/engine/core/dom/shadow/ComposedTreeWalker.cpp

Issue 704413007: Remove HTMLShadowElement. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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 | « sky/engine/core/core.gni ('k') | sky/engine/core/dom/shadow/ElementShadow.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/core/dom/shadow/ComposedTreeWalker.cpp
diff --git a/sky/engine/core/dom/shadow/ComposedTreeWalker.cpp b/sky/engine/core/dom/shadow/ComposedTreeWalker.cpp
index 62428a08e28cf10bdacb059394ca474bfd679556..09d09dd2b460417e1db39d10fbbe6ed60504d727 100644
--- a/sky/engine/core/dom/shadow/ComposedTreeWalker.cpp
+++ b/sky/engine/core/dom/shadow/ComposedTreeWalker.cpp
@@ -30,7 +30,6 @@
#include "core/dom/Element.h"
#include "core/dom/shadow/ElementShadow.h"
-#include "core/html/HTMLShadowElement.h"
namespace blink {
@@ -72,7 +71,7 @@ Node* ComposedTreeWalker::traverseNode(const Node* node, TraversalDirection dire
const InsertionPoint* insertionPoint = toInsertionPoint(node);
if (Node* found = traverseDistributedNodes(direction == TraversalDirectionForward ? insertionPoint->first() : insertionPoint->last(), insertionPoint, direction))
return found;
- ASSERT(isHTMLShadowElement(node) || (isHTMLContentElement(node) && !node->hasChildren()));
+ ASSERT(isHTMLContentElement(node) && !node->hasChildren());
return 0;
}
@@ -113,15 +112,7 @@ Node* ComposedTreeWalker::traverseSiblingInCurrentTree(const Node* node, Travers
Node* ComposedTreeWalker::traverseBackToYoungerShadowRoot(const Node* node, TraversalDirection direction)
{
- ASSERT(node);
- if (node->parentNode() && node->parentNode()->isShadowRoot()) {
- ShadowRoot* parentShadowRoot = toShadowRoot(node->parentNode());
- if (!parentShadowRoot->isYoungest()) {
- HTMLShadowElement* assignedInsertionPoint = parentShadowRoot->shadowInsertionPointOfYoungerShadowRoot();
- ASSERT(assignedInsertionPoint);
- return traverseSiblingInCurrentTree(assignedInsertionPoint, direction);
- }
- }
+ // FIXME(sky): Remove this.
return 0;
}
@@ -151,7 +142,6 @@ inline Node* ComposedTreeWalker::traverseParentOrHost(const Node* node) const
if (!parent->isShadowRoot())
return parent;
ShadowRoot* shadowRoot = toShadowRoot(parent);
- ASSERT(!shadowRoot->shadowInsertionPointOfYoungerShadowRoot());
if (!shadowRoot->isYoungest())
return 0;
return shadowRoot->host();
« no previous file with comments | « sky/engine/core/core.gni ('k') | sky/engine/core/dom/shadow/ElementShadow.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698