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

Unified Diff: sky/engine/core/css/resolver/SharedStyleFinder.cpp

Issue 928393003: Remove the concept of document.documentElement (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 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 | « sky/engine/core/core.gni ('k') | sky/engine/core/css/resolver/StyleAdjuster.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/core/css/resolver/SharedStyleFinder.cpp
diff --git a/sky/engine/core/css/resolver/SharedStyleFinder.cpp b/sky/engine/core/css/resolver/SharedStyleFinder.cpp
index 8ee85922e225ac59b2949de8396f8bdf0e612092..538e5f851bc86b30c0187ffc8e7b1e6f7c351e46 100644
--- a/sky/engine/core/css/resolver/SharedStyleFinder.cpp
+++ b/sky/engine/core/css/resolver/SharedStyleFinder.cpp
@@ -141,7 +141,7 @@ bool SharedStyleFinder::canShareStyleWithElement(Element& candidate) const
bool SharedStyleFinder::documentContainsValidCandidate() const
{
- for (Element* element = document().documentElement(); element; element = ElementTraversal::next(*element)) {
+ for (Element* element = ElementTraversal::firstChild(document()); element; element = ElementTraversal::next(*element)) {
if (element->supportsStyleSharing() && canShareStyleWithElement(*element))
return true;
}
« no previous file with comments | « sky/engine/core/core.gni ('k') | sky/engine/core/css/resolver/StyleAdjuster.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698